Updated docs for .search_sql() method

Also improved indentation of generated SQL queries. Refs #197
This commit is contained in:
Simon Willison 2020-11-08 09:04:33 -08:00
commit ce2b07c358
2 changed files with 12 additions and 10 deletions

View file

@ -1327,8 +1327,8 @@ class Table(Queryable):
columns_sql = "*"
columns_with_prefix_sql = "[{}].*".format(original)
if columns:
columns_sql = ", ".join("[{}]".format(c) for c in columns)
columns_with_prefix_sql = ", ".join(
columns_sql = ",\n ".join("[{}]".format(c) for c in columns)
columns_with_prefix_sql = ",\n ".join(
"[{}].[{}]".format(original, c) for c in columns
)
fts_table = self.detect_fts()