Re: [GENERAL] sorting Chinese varchar field

2005-03-28 Thread Tatsuo Ishii
> Great, that works out fine! > > So, the SQL I tested with is: > select * from mytable order by convert(name, 'utf8', 'gb18030'); Sorry, what I wanted to say was: SELECT * FROM t1 WHERE ... ORDER BY CONVERT(your_chinese_character using utf_8_to_gb_18030); Of course your example is fine too (a

Re: [GENERAL] sorting Chinese varchar field

2005-03-28 Thread jian chen
Great, that works out fine! So, the SQL I tested with is: select * from mytable order by convert(name, 'utf8', 'gb18030'); It produces the correct output. Thanks Tatsuo! Jian On Tue, 29 Mar 2005 10:25:58 +0900 (JST), Tatsuo Ishii <[EMAIL PROTECTED]> wrote: > > Hi, > > > > I installed postgres

Re: [GENERAL] sorting Chinese varchar field

2005-03-28 Thread Tatsuo Ishii
> Hi, > > I installed postgres 8.0 for windows on my win xp (Simplified Chinese > version). The encoding is unicode. When I set pgsql client encoding to > gb18030, I could insert Chinese text from the command line to > postgres. > > However, I could not get the sort order of Chinese varchar field

Re: [GENERAL] sorting Chinese varchar field

2005-03-28 Thread Magnus Hagander
>Hi, > >I installed postgres 8.0 for windows on my win xp (Simplified Chinese >version). The encoding is unicode. When I set pgsql client encoding to >gb18030, I could insert Chinese text from the command line to >postgres. > >However, I could not get the sort order of Chinese varchar field to >wor

[GENERAL] sorting Chinese varchar field

2005-03-28 Thread jian chen
Hi, I installed postgres 8.0 for windows on my win xp (Simplified Chinese version). The encoding is unicode. When I set pgsql client encoding to gb18030, I could insert Chinese text from the command line to postgres. However, I could not get the sort order of Chinese varchar field to work properl