diff --git a/migrations/20240203053645_fts.down.sql b/migrations/20240203053645_fts.down.sql new file mode 100644 index 0000000..0521f37 --- /dev/null +++ b/migrations/20240203053645_fts.down.sql @@ -0,0 +1,2 @@ +drop table if exists star_search; +drop table if exists watch_search; diff --git a/migrations/20240203053645_fts.up.sql b/migrations/20240203053645_fts.up.sql new file mode 100644 index 0000000..bb4b26d --- /dev/null +++ b/migrations/20240203053645_fts.up.sql @@ -0,0 +1,5 @@ +create virtual table if not exists star_search using fts5(name, id); +insert into star_search(name, id) select name, id from stars; + +create virtual table if not exists watch_search using fts5(title, id); +insert into watch_search(title, id) select title, id from watches;