On 6/08/2009 11:16 AM, Lukas Haase wrote: > Wes Freeman schrieb: > >> Strange that it's implemented for prefix and not postfix? > > Well, an explanation is easy: Same as with LIKE, LIKE 'xxx' or LIKE > 'xxx%' can be performed easy because only the beginning of words need to > be compared. > > However, there /is/ a way to also do postfix searches. I have the *same* > database in *.hlp format and with WinHelp it's possible to search > '*otor' (and others) with almost zero CPU and time consumption. I'd be > curious how they did this.
In memory: maybe a suffix tree. In a database: have a column with the words stored backwards. SELECT ... WHERE back_word LIKE "roto%" _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users