Re: More message encoding woes - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: More message encoding woes
Date
Msg-id 200904071238.09734.peter_e@gmx.net
Whole thread Raw
In response to Re: More message encoding woes  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Responses Re: More message encoding woes  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
List pgsql-hackers
On Tuesday 07 April 2009 11:21:25 Heikki Linnakangas wrote:
> Peter Eisentraut wrote:
> > In practice you get either the GNU or the Solaris version of gettext, and
> > at least the GNU version can cope with all the encoding names that the
> > currently Windows-only code path produces.
>
> It doesn't. On my laptop running Debian testing:
>
> hlinnaka@heikkilaptop:~$ LC_ALL=fi_FI.UTF-8 gettext
> gettext: ei riittävästi argumentteja
> hlinnaka@heikkilaptop:~$ LC_ALL=fi_FI.LATIN1 gettext
> gettext: missing arguments

That is because no locale by the name fi_FI.LATIN1 exists.

> hlinnaka@heikkilaptop:~$ LC_ALL=fi_FI.ISO-8859-1 gettext
> gettext: ei riitt�v�sti argumentteja
>
> Using the name for the latin1 encoding in the currently Windows-only
> mapping table, "LATIN1", you get no translation because that name is not
> recognized by the system. Using the other name "ISO-8859-1", it works.
> "LATIN1" is not listed in the output of locale -m either.

You are looking in the wrong place.  What we need is for iconv to recognize
the encoding name used by PostgreSQL.  iconv --list is the primary hint for
that.

The locale names provided by the operating system are arbitrary and unrelated.


pgsql-hackers by date:

Previous
From: Sergey Burladyan
Date:
Subject: Re: XML only working in UTF-8 - Re: 8.4 open items list
Next
From: Heikki Linnakangas
Date:
Subject: Re: More message encoding woes