Set LC_COLLATE to de_DE_phoneb

From: Frank Jagusch <frank(at)jagusch-online(dot)de>
To: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Set LC_COLLATE to de_DE_phoneb
Date: 2010-04-06 20:12:49
Message-ID: 1270584769.6242.31.camel@AMD3800.zuhause
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

How to set the collation of a database to the german phone book sort
order?
I did ask this on several places. Finally the moderator of pg-forum.de
recommended to ask here. See the discussion there:
http://www.pg-forum.de/konfiguration/4308-sortierfolge-de_de_phoneb.html

Environment: PostgreSQL 8.4.3 build 1400, 32 Bit, Windows XP

The usual german collation is "German_Germany.1252". This corresponds to
the windows language setting de_DE an in the registry (HKEY_CURRENT_USER
\control\Panel\International\Locale) to the value 00000407.

The german phone book order has the windows language setting
de_DE_phoneb an the value 00010407 in the registry. Unfortunately I was
not able to find a corresponding string for the LC_COLLATE setting.

I searched the sources of postgresql an found the function
IsoLocaleName(...) in src/backend/utils/adt/pg_locale.c. I guess this
should be the place for further investigations. Or am I wrong? I'm not
quite well in C and without some knowledge of the libraries behind I
make no progress. Can anyone help me out? Is there anywhere a
documentation or a "translation table" for the different representations
of the language settings between the postgresql- and the
windows-"world"?

Background: I moved an old application from a borland paradox database
to postgesql. The speed gain is great but the sorting order isn't the
usual to the user. I can't change the order by clauses of the select
statements because they are generated by the borland database engine.

Thanks in advance
Frank Jagusch
--
http://www.jagusch-online.de/cdlfj

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Merlin Moncure 2010-04-06 20:13:22 Re: SELECT constant; takes 15x longer on 9.0?
Previous Message Josh Berkus 2010-04-06 20:10:21 Re: SELECT constant; takes 15x longer on 9.0?