Testing version:
Version 2.1.6 (12537)
What were you doing:
Searching for a phrase containing an apostrophe
What feature did you use:
Search
What happened:
Received partial matches
What did you expect to happen:
I expected that searching for a term such as “bob’s” would also match against “bob’s” with the character '
replace by ’
but this does not happen.
This required some research: Notes and other stock apps work as you expected… but in an odd way. Notes produce search matches for both bob’s
and bob's
but, when the character is different inside the note, the match is not shown as an editor search match. Also, If I search for the apostrophe or the quote character no matches are presented.
The way all the punctuation characters are handled makes us think searches are performed on an index and not on the content of the notes as we do. Now we perform the search with a normal sqllite predicate by splitting the search term into tokens and composing the query for each token.
In theory, we can scan each token, search for special characters, and then double (or triple, quadruple, …) the query portion for each variation of the character but this comes with a cost in terms of performance even for the people not using apostrophe, quotes, …
Search performances concern me a lot personally but We’ll see what we can do and run some tests.
1 Like