mirror of
https://github.com/simonw/sqlite-utils.git
synced 2026-07-25 18:34:32 +02:00
sqlite-utils rebuild-fts command, closes #155
This commit is contained in:
parent
76548596a6
commit
176f4e0ef4
5 changed files with 93 additions and 2 deletions
|
|
@ -173,9 +173,9 @@ class Database:
|
|||
def table_names(self, fts4=False, fts5=False):
|
||||
where = ["type = 'table'"]
|
||||
if fts4:
|
||||
where.append("sql like '%FTS4%'")
|
||||
where.append("sql like '%USING FTS4%'")
|
||||
if fts5:
|
||||
where.append("sql like '%FTS5%'")
|
||||
where.append("sql like '%USING FTS5%'")
|
||||
sql = "select name from sqlite_master where {}".format(" AND ".join(where))
|
||||
return [r[0] for r in self.execute(sql).fetchall()]
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue