Re: BUG #14182: Wrong time stamp exactly at 1996 hour 3

From: John R Pierce <pierce(at)hogranch(dot)com>
To: olmozavala(at)gmail(dot)com, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #14182: Wrong time stamp exactly at 1996 hour 3
Date: 2016-06-08 21:39:52
Message-ID: 3b57d30b-b468-d290-daf1-65b22b7af16f@hogranch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On 6/8/2016 1:37 PM, olmozavala(at)gmail(dot)com wrote:
> If you create a table with just id and mydate (timestamp without zone) and
> then you execute:
>
> INSERT INTO test (fecha) VALUES
> (to_timestamp('07/04/1996/2','DD/MM/YY/HH24'))
> INSERT INTO test (fecha) VALUES
> (to_timestamp('07/04/1996/3','DD/MM/YY/HH24'))
>
> It should give you two different hours, but it will give you the same hour.
> I was filling a very large database and this problem seems to appear only at
> this specific date and time.

that date/time is exactly when DST began that year in the USA... The
function to_timestamp returns a timestamptz (timestamp with time zone).

--
john r pierce, recycling bits in santa cruz

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message John R Pierce 2016-06-08 21:50:23 Re: BUG #14182: Wrong time stamp exactly at 1996 hour 3
Previous Message olmozavala 2016-06-08 20:37:33 BUG #14182: Wrong time stamp exactly at 1996 hour 3