COLLATION parameter in SQL query
Posted by: Foton
Date: March 13, 2006 10:08AM

I have MySql 3.23.58-nt and database with :
character set: latin1
character sets: latin1 big5 czech euc_kr gb2312 gbk sjis tis620 ujis dec8 dos german1 hp8 koi8_ru latin2 swe7 usa7 cp1251 danish hebrew win1251 estonia hungarian koi8_ukr win1251ukr greek win1250 croat cp1257 latin5 (info by PHPMyAdmin 2.5.6)

and I can not change it.

The data (varchar) was send in win-1250 encoding, but stored in latin1 table.
My problem is that when I want to display and sort table by "ORDER BY"
SQL parameter, there are not sorted right.

So I try to use SQL command " SELECT * FROM table ORDER BY name COLLATION cp1250_general_ci LIMIT 0,30".

But answer from PHPMyAdmin is:
"#1064 - You have an error in your SQL syntax near 'COLLATION cp1250_general_ci LIMIT 0, 30' at line 4 "

What is wrong?
Me? DB? MySQL? PHP? God?


Options: ReplyQuote

Written By
COLLATION parameter in SQL query
March 13, 2006 10:08AM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.