Re: 'order by' does "wrong" with unicode-chars (german umlauts)
От | peter pilsl |
---|---|
Тема | Re: 'order by' does "wrong" with unicode-chars (german umlauts) |
Дата | |
Msg-id | 1064075975.3f6c82c7064bc@www.goldfisch.at обсуждение исходный текст |
Ответ на | Re: 'order by' does "wrong" with unicode-chars (german umlauts) (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: 'order by' does "wrong" with unicode-chars (german umlauts)
|
Список | pgsql-general |
It makes no difference if I use a database with encoding unicode: # \l List of databases Name | Owner | Encoding --------------------+--------------+----------- <skip> test | peter | SQL_ASCII unicode | peter | UNICODE unicode2 | peter | LATIN1 I tried with all these databases. The problem stays exactely the same. The german umlaut-O appears as double-byte "ö" and when ordering it appears between "A" and "B", cause imho only the first byte "Ã" is taking into account. I still have no idea, if there is a problem outside postgreSQL (in perl or maybe in the DBD::Pg-interface) or inside postgreSQL. I still struggle with serious debugging cause I dont know how to insert "real" unicode into postgres ... Any debugging-hints welcome also :) Dealing with the UNICODE-database raises new problems: unicode=# insert into test values ('österreich'); ERROR: Unicode >= 0x10000 is not supported unicode=# show client_encoding; client_encoding ----------------- UNICODE (1 row) thnx, peter Quoting Tom Lane <tgl@sss.pgh.pa.us>: > peter pilsl <pilsl@goldfisch.at> writes: > > I get my text from a web-form, process it via perl and store it in > postgreSQL > > via DBI-Interface. The unicode-text appears as multibyte in perl and I got > the > > suspect that postgresql simply takes this multibyte-text and doesnt even > > reckognize that it could be unicode. > > If you have set the database encoding as SQL_ASCII, then that's exactly > what it will (and should) do. You need to make the database encoding > be unicode. > > regards, tom lane > >
В списке pgsql-general по дате отправления: