I have a MySQL database with words containing accents in Spanish (áéíóú). I\'d like to know if there\'s any way to do a diacritic insensitive search. For instance, if I sear
You can force the column name to convert as UTF8. I haven't tried is for Spanish but rather for Romanian characters with accents, but I assume it's the same thing.
The query I use is:
SELECT CONVERT('gîgă' USING utf8) LIKE '%giga%'
Or in the more likely case of looking up a column in a table, you can use:
SELECT CONVERT(column_name USING utf8) FROM table_name LIKE '%giga%'