[TYPO3-dev] MySQL, search and utf8

Martin Kutschker martin.kutschker-n0spam at no5pam-blackbox.net
Mon Oct 8 20:05:00 CEST 2007


Steffen Kamper schrieb:
> Hi,
> 
> i have a non-TYPO3-question.
> 
> I perform a search in MySQL and for example look for the word "schön". So my 
> query looks like:
> 
> Select .... where ... and (body like "schön%" or body like "%schön%" or body 
> like "%schön" or body = "schön")
> 
> looking to the results i see that MySQL shows up result with the word 
> "schon" which is different. Thoug it is utf8, the letter ö is saved in utf8 
> as 2-Byte, so why gives MySQL me the result with o?

Mysql knows three character sets: the one the clients sends (queries), 
the one the server uses (data storage) and the one the the server sends 
(query results).

Seems like the last settings is for some reason not UTF8. See the Mysql 
docs on how to set (and check) those settings.

Masi




More information about the TYPO3-dev mailing list