there are several documents about java, javascript etc..
the wordlist table in the search index sqlite has the terms 'java', 'javascript', 'javase' , 'java-interview'
asYouType is enabled
a user is searching for 'java' and expects to get results for 'java', 'javascript' , etc...
Only search results for 'java' are returned because TNTSearch::getWordlistByKeyword only returns 'java' because of SELECT * FROM wordlist WHERE term like :keyword ORDER BY length(term) ASC, num_hits DESC LIMIT 1 (l. 308) --> is this by mistake or by intention? In my opinion, when asYouType is enabled the wordlist returned should contain all the words starting with 'java', so the LIMIT 1 could be removed?
Hey,
Lets have a look at this case:
wordlist
table in the search index sqlite has the terms 'java', 'javascript', 'javase' , 'java-interview'asYouType
is enabledOnly search results for 'java' are returned because
TNTSearch::getWordlistByKeyword
only returns 'java' because ofSELECT * FROM wordlist WHERE term like :keyword ORDER BY length(term) ASC, num_hits DESC LIMIT 1
(l. 308) --> is this by mistake or by intention? In my opinion, whenasYouType
is enabled the wordlist returned should contain all the words starting with 'java', so theLIMIT 1
could be removed?