add full text search to db
This commit is contained in:
parent
a680d01d7f
commit
24c67bc529
2 changed files with 7 additions and 0 deletions
2
migrations/20240203053645_fts.down.sql
Normal file
2
migrations/20240203053645_fts.down.sql
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
drop table if exists star_search;
|
||||||
|
drop table if exists watch_search;
|
5
migrations/20240203053645_fts.up.sql
Normal file
5
migrations/20240203053645_fts.up.sql
Normal file
|
@ -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;
|
Loading…
Reference in a new issue