I have been relying on MySQL’s Full-Text search index for sometime.
Recently a user ran into a black hole in that feature.
He wanted to find records containing a simple phrase, “thank you”.
But, the search resulted in no records found.
You see, “thank” and “you” are stop words in the default full-text index. Meaning they are discarded or given no relevance in the search results.
After some digging, I discovered that others have run into this same limitation and opted to remove the default stop word list.
Quick fix? Not quite.
Removing the stop word list, forces you to rebuild the index. Which on my modestly sized database meant 30 minutes of downtime on that table.
Fair enough. I performed that over the weekend.
Fast forward a couple days. Guess what happens now?
Other users are getting less than stellar search results - of course. Seemed a fair trade off at the time, between the two extremes.
I could keep tuning the stop words and narrowing the gap between the two extremes, but tuning mysql full-text index takes far too long because of the table locking required to rebuild the index.
So I am moving on to external search indexers, like Sphinx. Which can rebuild the entire index in a few minutes without requiring the downtime for the users.

2 responses so far ↓
1 Warren Smith // Apr 03, 2008 at 10:34 PM
2 Lon // May 19, 2008 at 08:19 PM
Leave a Comment