Re: PDT but not WEST - Mailing list pgsql-general

From Steve Crawford
Subject Re: PDT but not WEST
Date
Msg-id 4E84BCA7.1030403@pinpointresearch.com
Whole thread Raw
In response to Re: PDT but not WEST  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: PDT but not WEST
Re: PDT but not WEST
Re: PDT but not WEST
List pgsql-general
On 09/29/2011 10:50 AM, Tom Lane wrote:
> Christophe Pettus<xof@thebuild.com>  writes:
>> I am baffled.  Both PDT and WEST appear as valid timezone abbreviations, and each have unique values, but:
> Where do you see WEST as a valid timezone abbrevation?  It's not listed
> in the "Default" abbreviation list.  (Perhaps it should be, since there
> don't seem to be any places that don't consider it GMT+1 summer time.)
>
>             regards, tom lane
>
select * from pg_timezone_names where abbrev = 'WEST' ;
           name          | abbrev | utc_offset | is_dst
------------------------+--------+------------+--------
  Portugal               | WEST   | 01:00:00   | t
  posix/Portugal         | WEST   | 01:00:00   | t
  posix/WET              | WEST   | 01:00:00   | t
  posix/Europe/Lisbon    | WEST   | 01:00:00   | t
  posix/Atlantic/Canary  | WEST   | 01:00:00   | t
  posix/Atlantic/Faeroe  | WEST   | 01:00:00   | t
  posix/Atlantic/Madeira | WEST   | 01:00:00   | t
  posix/Atlantic/Faroe   | WEST   | 01:00:00   | t
  WET                    | WEST   | 01:00:00   | t
  Europe/Lisbon          | WEST   | 01:00:00   | t
  Atlantic/Canary        | WEST   | 01:00:00   | t
  Atlantic/Faeroe        | WEST   | 01:00:00   | t
  Atlantic/Madeira       | WEST   | 01:00:00   | t
  Atlantic/Faroe         | WEST   | 01:00:00   | t
(14 rows)

It's interesting that there are (in my install of 9.1):

1174 distinct timezone names (all records are unique) in pg_timezone_names.
181 distinct abbreviations in pg_timezone_names

189 distinct timezone abbreviations (all unique abbreviations) in
pg_timezone_abbrevs.

But 61 abbreviations that appear in pg_timezone_names do not have a
corresponding entry in pg_timezone_abbrevs and 69 abbreviations in
pg_timezone_abbrevs that don't appear in pg_timezone_names.

There are 56 records and 3 different offsets in pg_timezone_names for
the abbreviation 'CST'.

I try to use timezone names instead of abbreviations wherever possible.

Cheers,
Steve

pgsql-general by date:

Previous
From: Christophe Pettus
Date:
Subject: Re: PDT but not WEST
Next
From: John R Pierce
Date:
Subject: Re: PDT but not WEST