Re: timezone offsets and documentation

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Kris Jurka <books(at)ejurka(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: timezone offsets and documentation
Date: 2005-10-22 19:27:21
Message-ID: 3087.1130009241@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Quite some time ago, Kris Jurka <books(at)ejurka(dot)com> wrote:
> This allows:

> jurka=# set timezone to 'Etc/GMT-14';
> SET
> jurka=# select '00:00:00'::timetz;
> timetz
> -------------
> 00:00:00+14
> (1 row)

> but this is not an allowed value:

> jurka=# select '00:00:00+14'::timetz;
> ERROR: time zone displacement out of range: "00:00:00+14"

Yeah. It's worse than that actually, because we will take something
like

SET TIMEZONE TO 'Etc/GMT+15';

I haven't traced through the code but I bet this is being accepted by
the "POSIX zone name" rule. Perhaps we should sanity-check the computed
offset?

I'm not sure what the use of GMT-14 is, but I suggest that we ought to
defer to the judgment of the zic people in making it available.
Accordingly, we probably ought to modify the range of allowed timezone
offsets to allow -14:00 (and maybe +14:00 as well?)

Comments?

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Mike Clements 2005-10-22 20:33:43 BUG #1988: keygen not implemented
Previous Message Tom Lane 2005-10-22 18:55:53 Re: BUG #1986: Please include ONE BIG .txt and .HTML file in *docs*.tar.gz