pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Christopher Sawtell <csawtell@xtra.co.nz>
Cc: Glen and Rosanne Eustace <agree@godzone.net.nz>
Cc: pgsql-sql@postgresql.org
Subject: Re: Re: Problem with Dates
Date: Fri, 26 Jan 2001 10:05:15 -0500
Message-ID: <29575.980521515@sss.pgh.pa.us> (raw)
In-Reply-To: <01012621220800.13520@berty>
References: <00ff01c0863e$c4ef8620$0101a8c0@godzone.net.nz>
	<20010124181731.G17481@thune.yy.com>
	<00d401c08729$077cc440$0101a8c0@godzone.net.nz>
	<01012621220800.13520@berty>

Christopher Sawtell <csawtell@xtra.co.nz> writes:
> On Fri, 26 Jan 2001 12:46, Glen and Rosanne Eustace wrote:
> [ ... ]

>> template1=# select '31/12/2000'::date + '365 days'::timespan;
>> ?column?
>> ------------------------
>> 2002-01-01 00:00:00+13    <<<<<<<<<<< Wrong
>> (1 row)

> [ ... ]

> I get the same result. This business of crooked dates in NZ summertime
> is frequently because the rest of the world can't  twig on to the notion that
> it is possible to have GMT + 13, and do not take account of it in date/time 
> calculations.

Could one of you try it in 7.1 (beta3 or later)?  We've changed some
details of the way daylight-savings transitions are handled in
date-to-timestamp conversions, so I think this might be fixed now.
It's worth checking anyway.

Also, what do you get from '31/12/2000'::date::timestamp?

			regards, tom lane



view thread (19+ messages)  latest in thread

Message-ID: <29575.980521515@sss.pgh.pa.us>
Permalink:  ../29575.980521515@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/29575.980521515@sss.pgh.pa.us

 · 

reply

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-sql@postgresql.org
  Cc: tgl@sss.pgh.pa.us, csawtell@xtra.co.nz, agree@godzone.net.nz
  Subject: Re: Problem with Dates
  In-Reply-To: <29575.980521515@sss.pgh.pa.us>
  References: <00ff01c0863e$c4ef8620$0101a8c0@godzone.net.nz> <20010124181731.G17481@thune.yy.com> <00d401c08729$077cc440$0101a8c0@godzone.net.nz> <01012621220800.13520@berty> <29575.980521515@sss.pgh.pa.us>

* 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