-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Behaviour of scout changed in 3.0.0 version #4
Comments
What SQLite full-text search version were you using previously? Was your SQLite compiled with support for FTS5? |
You know, I'm not sure that this actually worked as you described it... I tried running some SQL locally: -- create fts4 and fts5 tables
create virtual table idx4 using "fts4" (content);
create virtual table idx5 using "fts5" (content);
-- insert 3 sample rows into each
insert into idx4 (content) values ('hello world'), ('this is a test'), ('python is wonderful');
insert into idx5 (content) values ('hello world'), ('this is a test'), ('python is wonderful');
-- query index using complete and partial strings
select * from idx4 where idx4 match 'hello';
-- returns hello world
select * from idx4 where idx4 match 'hell';
-- no results returned
select * from idx4 where idx4 match 'ello';
-- no results returned
select * from idx5 where idx5 match 'hello';
-- returns hello world
select * from idx5 where idx5 match 'hell';
-- no results returned
select * from idx5 where idx5 match 'ello';
-- no results returned |
Y'know, I think this might be the difference that is causing the issue you've seen: Line 108 in 3107c01
Let me re-add the prefix option and see what happens. |
Well, that didn't really change anything :/ Nevermind. |
Feel free to add more info here in the comments. In the meantime I am going to close this. |
Funnily enough this doesn't work for english, works for hindi. -- create fts4 and fts5 tables
create virtual table idx4 using "fts4" (content);
create virtual table idx5 using "fts5" (content);
-- insert 1 sample rows into each
insert into idx4 (content) values ('नीरजा भनोट के कातिल पाकिस्तान की जेल में थे, फिर वे एफबीआई आए?');
insert into idx5 (content) values ('नीरजा भनोट के कातिल पाकिस्तान की जेल में थे, फिर वे एफबीआई आए?');
-- query index using complete and partial strings
select * from idx4 where idx4 match 'पाकिस्तान';
-- returns नीरजा भनोट के कातिल पाकिस्तान की जेल में थे, फिर वे एफबीआई आए?
select * from idx4 where idx4 match 'पाकि';
-- no results returned
select * from idx5 where idx5 match 'पाकिस्तान';
-- returns नीरजा भनोट के कातिल पाकिस्तान की जेल में थे, फिर वे एफबीआई आए?
select * from idx5 where idx5 match 'पाकि';
-- returns नीरजा भनोट के कातिल पाकिस्तान की जेल में थे, फिर वे एफबीआई आए? |
Strange! I have no idea what's going on but you may want to bring this up on the SQLite-users mailing list if you're curious for more details. |
Search Not working for substrings.
Example:
scout.create_document("hello this is just a dummy text","articles")
and searching
http://localhost:8000/articles/?q=ello
does not give any result
The text was updated successfully, but these errors were encountered: