From 79109939c39c16fd206010ef179040d59704682b Mon Sep 17 00:00:00 2001 From: Simon Willison Date: Sun, 8 Nov 2020 09:00:43 -0800 Subject: [PATCH] search --limit now defaults to everything, refs #192 --- docs/cli.rst | 5 ++--- sqlite_utils/cli.py | 3 +-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/docs/cli.rst b/docs/cli.rst index a122234..4e9710d 100644 --- a/docs/cli.rst +++ b/docs/cli.rst @@ -933,15 +933,14 @@ Use the ``--sql`` option to output the SQL that would be executed, rather than r from [documents] ) select - original.*, - [documents_fts].rank as rank + [original].* from [original] join [documents_fts] on [original].rowid = [documents_fts].rowid where [documents_fts] match :query order by - rank + [documents_fts].rank .. _cli_vacuum: diff --git a/sqlite_utils/cli.py b/sqlite_utils/cli.py index 468e6b4..cfc57c6 100644 --- a/sqlite_utils/cli.py +++ b/sqlite_utils/cli.py @@ -986,8 +986,7 @@ def query( @click.option( "--limit", type=int, - default=20, - help="Number of rows to return, default 20, set to 0 for unlimited", + help="Number of rows to return - defaults to everything", ) @click.option( "--sql", "show_sql", is_flag=True, help="Show SQL query that would be run"