From: Heikki Linnakangas <hlinnakangas@vmware.com>
To: frank@heuveltop.nl
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #8135: current_setting('DateStyle'); does not reflect User setting
Date: Mon, 06 May 2013 10:21:46 +0300
Message-ID: <51875A0A.5000407@vmware.com> (raw)
In-Reply-To: <E1UZ3Va-0003QK-KE@wrigleys.postgresql.org>
References: <E1UZ3Va-0003QK-KE@wrigleys.postgresql.org>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
On 05.05.2013 21:18, frank@heuveltop.nl wrote:
> PostgreSQL version: 9.1.8
Not that it makes any difference for this issue, but you should upgrade
to 9.1.9.
> After
> ALTER ROLE frank SET TimeZone = 'Europe/Amsterdam';
>
> Where the TimeZone differs from the default timezone.
>
> SELECT current_setting('TimeZone');
>
> Gives the correct answer.
>
> But this same doesn't work for DateStyle
>
> ALTER ROLE frank SET DateStyle = 'SQL, DMY';
>
> Where the DateStyle differs from the default DateStyle
>
> SELECT current_setting('DateStyle');
>
> Gives the system/database setting but not the user setting; while the
> setting does have its effect on the output of date's and timestamps. This
> might also effect other user settings, but I haven't found any yet.
Works for me. Are you sure the value isn't being overridden by a
per-database-and-role setting? You can use "select source from
pg_settings where name='DateStyle'" to check where the currently
effective value came from.
- Heikki
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: hlinnakangas@vmware.com, frank@heuveltop.nl
Subject: Re: BUG #8135: current_setting('DateStyle'); does not reflect User setting
In-Reply-To: <51875A0A.5000407@vmware.com>
References: <E1UZ3Va-0003QK-KE@wrigleys.postgresql.org> <51875A0A.5000407@vmware.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox