Re: NLS on MSVC strikes back! - Mailing list pgsql-hackers

From Gevik Babakhani
Subject Re: NLS on MSVC strikes back!
Date
Msg-id 000d01c86da0$d78a5020$0a01a8c0@gevmus
Whole thread Raw
In response to Re: NLS on MSVC strikes back!  (Alvaro Herrera <alvherre@commandprompt.com>)
List pgsql-hackers
> What this really means is that locale support is completely 
> broken in the MSVC build, i.e. you cannot get localized 
> strings at all (not just to_char()).  Is this correct?  If 
> so, this is a serious problem.
> 

The way one could confirm this is by:

1. rename share/locale/de to share/locale/German_Germany
2. start a dosbox
3. before starting PG, set an env variable SET LANGUAGE=German_Germany in
that dosbox, which will force all child threads to have that locale.
3. start PG form that dosbox and SET LC_MESSAGES to "es_ES" or
"Spanish_Spain" or "es_ES.utf8" or anything else...; select
to_char(now(),'TMDay TMMonth YYYY');
4. The result will be in German and not Spanish as one expects.


If handling locale in to_char will remain using gettext then I can start
working on a patch to fix this.

Regards,
Gevik Babakhani
------------------------------------------------
PostgreSQL NL       http://www.postgresql.nl
TrueSoftware BV     http://www.truesoftware.nl
------------------------------------------------



pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Patch review
Next
From: Bruce Momjian
Date:
Subject: Re: Patch review