SQLite3, FTS3 and stop-words
How do you prevent SQLite3 from not indexing certain key words, or "stop-words", during the build of a virtual FTS3 table?
开发者_JAVA技巧Examples I'd like to not index include "is", "the", "a" etc.
Unfortunately there is no built in tokenizer that handles stop words, so you will either need to implement your own tokenizer in C and filter out the stop words from the list manually, insert pre-tokenized/pre-filtered text into the relevant FTS table column or use a somewhat convoluted scheme where you insert the text into the FTS column, fetch it back after its been tokenized, filter it and then update the column value.
精彩评论