timestamp problem - Mailing list pgsql-novice

From Wright, George
Subject timestamp problem
Date
Msg-id 51548D6D5BEB57468163194A8C1A0E9831954D@MAGPTCPEXC02.na.mag-ias.net
Whole thread Raw
In response to Re: Problem with createdb  (Durgaprasad Pawar <durgaprasad.pawar@yahoo.co.in>)
Responses Re: timestamp problem  (Michael Glaesemann <grzm@seespotcode.net>)
List pgsql-novice

I seem to be getting an incorrect result from the isfinite postgresql call when querying an invalid time in the DST change.

 

The OS is Suse 10.2, timezone files have been updated with the files in tzdata2007h.tar.gz.

 

This shows proper installation of the timezone files:

myhost:/ # zdump -v Brazil/East | grep 2007

Brazil/East  Sun Feb 25 01:59:59 2007 UTC = Sat Feb 24 23:59:59 2007 BRST isdst=1 gmtoff=-7200

Brazil/East  Sun Feb 25 02:00:00 2007 UTC = Sat Feb 24 23:00:00 2007 BRT isdst=0 gmtoff=-10800

Brazil/East  Sun Oct 14 02:59:59 2007 UTC = Sat Oct 13 23:59:59 2007 BRT isdst=0 gmtoff=-10800

Brazil/East  Sun Oct 14 03:00:00 2007 UTC = Sun Oct 14 01:00:00 2007 BRST isdst=1 gmtoff=-7200

 

The settings on the box are Brazil East. The hour of 2007-10-14 00:00:00 to 2007-10-14 00:59:59 does not exist. In that part of Brazil they move the clock from midnight to 1am as they step forward into DST.

 

myhost=> select isfinite(timestamp '2007-10-14 00:00:00 BRST');

 isfinite

----------

 t

(1 row)

 

Changing to standard time returns the same result:

 

myhost=> select isfinite(timestamp '2007-10-14 00:00:00 BST');

 isfinite

----------

 t

(1 row)

 

This should fail as it does for something like:

 

badger=> select isfinite(date '2007-10-14 24:00:01');

ERROR:  date/time field value out of range: "2007-10-14 24:00:01"

 

Did I miss something?

 

 

pgsql-novice by date:

Previous
From: Durgaprasad Pawar
Date:
Subject: Re: Problem with createdb
Next
From: Michael Glaesemann
Date:
Subject: Re: timestamp problem