[TYPO3-dev] Some minor problems with fetching from database

Erik Svendsen erik at linnearad.no
Thu Jun 18 17:15:45 CEST 2009


Marc Wöhlken skrev:
> Hi Erik!
> Erik Svendsen schrieb:
> 
>> I'm pretty sure the code is correct, as it works as it should except for
>> to letters. But the problem with A and Á is annoying me.
> 
> This is probably caused by something called collation under MySQL - see
> http://dev.mysql.com/doc/refman/5.1/en/charset-general.html
> 
> In simple words a collation describes how to order and compare
> characters. You should probably choose a suitable collation for your
> character set and language.
> 
> Regards
>  Marc
> 

Doesn't help as far as I has tested. I'm aware of collation, and this 
are tested with different collations for both the table and the title 
field. And the only collation which can be used on the field is 
utf8_danish_ci, because of the sorting of Æ,Ø,Å,and necessary to pick 
Æ,Ø,Å correct. utf8_swedish_ci also picks correct records (exept A and 
Á), but sorts Æ,Ø,Å wrong.

Wrong collation should also gives error on other characters, for 
instance sorted Å together with A, and Ø together with O.

When you are working with webpages which has Norwegian Bokmål (nb_NO), 
Norwegian Nynorsk (nn_NO), Nothern Sami (se_NO), Southern Sami (sma_NO), 
  English versions and shall have versions on Urdu in the future you 
really see that either MySQL or PHP are really good on localization.

So i don't think localisation is the problem. A possible problem is 
multibyte, but then should I also had problem with all these characters. 
Æ Ø Å Č Đ Ŋ Š Ŧ

I should have told that everything from A - Z are utf-8.

Regards

Erik




More information about the TYPO3-dev mailing list