Forum Moderators: coopster

Message Too Old, No Replies

Order BY "text" not correct in Japanese

Does not order the list correctly in Japanese

         

whats up skip

12:36 am on Nov 26, 2003 (gmt 0)

10+ Year Member



I have a list of names in Japanese and when you use the ORDER BY function in myphpadmin or in a php script coming from a mySQL data base it does not order correctly.

It seems to get the first few write then loose the plot completely.

Using Shift JIS encoding.

Timotheos

1:22 am on Nov 26, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Well I guess the first thing to ask is if you've got mysql set up to use Shift JIS encoding? I think it's in the config file. What version of mySQL are you using?

whats up skip

1:45 am on Nov 26, 2003 (gmt 0)

10+ Year Member



Running mysql (4.0.15-standard)

It is a hosted service, so I am not sure that I can access the mysql config file. Any thoughts on this?

Timotheos

4:57 pm on Nov 26, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I've worked a little with Japanese characters but not in mySQL. That said, I'm sure your server is defaulted to latin-1 and therefore the multibyte Japanese characters will not sort or group correctly. See character set sorting [mysql.com] in the manual. There's the PHP function mysql_client_encoding [php.net] to determine this as well. Maybe you could talk to your host and see what they can do. Otherwise I'm not sure how to do it easily.