Strange problem with MySQL full text query
Posted
by Manish
on Stack Overflow
See other posts from Stack Overflow
or by Manish
Published on 2010-04-13T06:56:33Z
Indexed on
2010/04/13
7:32 UTC
Read the original article
Hit count: 548
mysql
|full-text-search
This probably has something to do with my understanding of full text search or perhaps a known issue. My Java code creates search term for full text search on MySQL like this -
+word*
This works fine if the value in the DB column contains more text than the word itself. However, if the value is exact - no result are returned. I expected it to return results when value is an exact match. Let me give an example - Assume that DB has column name with value "Manish", now if I search with this - +Manis*
It does return the result correctly, but if I try this - +Manish* It doesn't return any result, though exact match exists in DB column - Name. How can I obtain the desired behaviour in both these cases? Removing + sign works, but it returns far too many results when there are two or more words.
Any help, pointers would be highly appreciated! I am using MySQL 5.0
TIA, - Manish
© Stack Overflow or respective owner