Re: a contrib function to query current locale values

From: Karel Zak <zakkr(at)zf(dot)jcu(dot)cz>
To: Hannu Krosing <hannu(at)tm(dot)ee>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: a contrib function to query current locale values
Date: 2001-02-07 09:20:35
Message-ID: Pine.LNX.3.96.1010207100604.16736A-100000@ara.zf.jcu.cz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


On Wed, 7 Feb 2001, Hannu Krosing wrote:

>
> Hi,
>
> I've written a small function that should go into contrib for 7.1
>
> As locale issues are quite tricky, being able to find out what locale
> backend thinks it is in is a good thing ;)

hmm, see you PG sources -- pg_locale.c file?

I mean that is not good lavish the sources with same code. If this is
really needful will better add your idea into this file and use
PGLC_current() instead add to sources again new setlocale() call.

The current backend (unfortunately) disable change locales on the fly
-- this means your function will returns always same result :-)

IMHO more nice will some function 'environment()' returns *all* backend
environment values (locales, debug mode ... etc) or command "SHOW LOCALE"
or something like this.

Karel

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Emmanuel Charpentier 2001-02-07 11:57:44 Re: ODBC Problem v7.1 beta4
Previous Message Peter T Mount 2001-02-07 08:37:48 Re: using the same connection?