I have a simple MySQL table that is setup for full text search.
| id | title |
----------------------
| 1 | test event |
| 2 | Second test |
| 3 | Larry's event |
| 4 | this second |
When I use the query:
SELECT *
FROM EVENTS
WHERE MATCH (title) AGAINST ('test event' IN BOOLEAN MODE);
I get back 3 rows; the ones containing 'test event', 'Second test', and 'Larry's Event'.
Now If I run the following query:
SELECT *
FROM EVENTS
WHERE MATCH (title) AGAINST ('second' IN BOOLEAN MODE);
Nothing is returned... strange?
Lastly, if I run the query:
SELECT *
FROM EVENTS
WHERE MATCH (title) AGAINST ('second test' IN BOOLEAN MODE);
I get back 2 rows; the ones containing 'test event' and 'Second test'.
I appears that the word 'second' cannot be searched or needs to be escaped somehow. Am I missing something?