AT TIME ZONE and DST in UTC<->CET conversion - Mailing list pgsql-general

From Jaromír Talíř
Subject AT TIME ZONE and DST in UTC<->CET conversion
Date
Msg-id 1215252724.3017.12.camel@localhost
Whole thread Raw
Responses Re: AT TIME ZONE and DST in UTC<->CET conversion
List pgsql-general
First, if I do conversion from UTC to CET and back when a timestamp is
OUTSIDE of daylight saving period, it's correct:

postgres# select '2008-01-01 10:10:10 UTC' AT TIME ZONE 'CET';
      timezone
---------------------
 2008-01-01 11:10:10

postgres# select '2008-01-01 11:10:10 CET' AT TIME ZONE 'UTC';
      timezone
---------------------
 2008-01-01 10:10:10


When I do the same INSIDE this period just the UCT->CET direction is
correct but back direction will fail subtracting only 1 hour instead of
2 hours.

postgres# select '2008-06-01 10:10:10 UTC' AT TIME ZONE 'CET';
      timezone
---------------------
 2008-06-01 12:10:10

postgres# select '2008-06-01 12:10:10 CET' AT TIME ZONE 'UTC';
      timezone
---------------------
 2008-06-01 11:10:10

If it supports automatic discovery of DST in conversion from UTC to CET
(and this is great), why it doesn't support this discovery in opposit
direction?

Regards,
Jaromir

Attachment

pgsql-general by date:

Previous
From: dushy
Date:
Subject: Re: [Postgresql 8.2.3] autovacuum starting up even after disabling ?
Next
From: Gregory Stark
Date:
Subject: Re: AT TIME ZONE and DST in UTC<->CET conversion