From c4bb84a88f0fa84a28f4c67a56763ada3235d0be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gwendal=20Roue=CC=81?= Date: Wed, 25 Apr 2018 09:10:03 +0200 Subject: [PATCH] Fix outdated documentation --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 145531e45..1f7d7991c 100644 --- a/README.md +++ b/README.md @@ -7231,7 +7231,7 @@ Database accesses that run in background threads postpone the closing of connect When you want to debug a request that does not deliver the expected results, you may want to print the SQL that is actually executed. -Use the `asSQLRequest` method: +You can turn your request into a `SQLRequest` instance: ```swift try dbQueue.read { db in @@ -7239,7 +7239,7 @@ try dbQueue.read { db in .filter(Column("origin") == "Burgundy") .order(Column("price") - let sqlRequest = try request.asSQLRequest(db) + let sqlRequest = try SQLRequest(db, request: request) print(sqlRequest.sql) // Prints SELECT * FROM wines WHERE origin = ? ORDER BY price print(sqlRequest.arguments)