Re: psql: set \encoding according to the current locale

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Martin Pitt <martin(at)piware(dot)de>
Cc: PostgreSQL Bugs <pgsql-bugs(at)postgresql(dot)org>, 223272(at)bugs(dot)debian(dot)org
Subject: Re: psql: set \encoding according to the current locale
Date: 2004-11-02 08:38:07
Message-ID: 200411020938.07697.peter_e@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Am Sonntag, 31. Oktober 2004 22:59 schrieb Martin Pitt:
> Currently (i. e. in 7.4.6) psql seems to use the default database
> encoding as locale for both its own messages and for database output
> strings. Whereas it is only an inconvenience for the latter, psql's
> own messages should really respect LANG/LC_MESSAGES environment
> variables instead of the database encoding.

That's what it does.

> It would also be nice to call "set \encoding" to match the locale psql
> was called under, at least when it is called interactively.

There is no portable interface to match locale encodings to PostgreSQL's
encoding names.

--
Peter Eisentraut
http://developer.postgresql.org/~petere/

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message PostgreSQL Bugs List 2004-11-02 13:46:51 BUG #1303: backend crashes due wrong TCP packet
Previous Message Laferriere, Al 2004-11-02 07:09:15 Re: 8.0 beta4: Exception when including catalog qualifier in SELECT from