Re: BUG #1117: Time calculation from epoch is 12 hours out - Mailing list pgsql-bugs

From Stephan Szabo
Subject Re: BUG #1117: Time calculation from epoch is 12 hours out
Date
Msg-id 20040326195104.M83786@megazone.bigpanda.com
Whole thread Raw
In response to BUG #1117: Time calculation from epoch is 12 hours out  ("PostgreSQL Bugs List" <pgsql-bugs@postgresql.org>)
List pgsql-bugs
On Fri, 26 Mar 2004, PostgreSQL Bugs List wrote:

> The following bug has been logged online:
>
> Bug reference:      1117
> Logged by:          Neil Cooper
>
> Email address:      neil.cooper@scigames.com
>
> PostgreSQL version: 7.3.4
>
> Operating system:   Red Hat ES 3.0
>
> Description:        Time calculation from epoch is 12 hours out
>
> Details:
>
> I'm using the PostgreSQL that comes with Red Hat ES 3.0. (psql reports
> 7.3.4-R.H). For purposes of testing/reporting, my workstation is running on
> UTC time to avoid any potential timezone confusions.
>
> OK heres the problem:
>
> The output of the following query:
> select '1970-1-1 00:00:00'::timestamp + '1080302400 seconds'::reltime;

It seems to be a problem with reltime.  I'd suggest just avoiding reltime
entirely and using interval instead.

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #1117: Time calculation from epoch is 12 hours out
Next
From: Bruno Wolff III
Date:
Subject: Re: Bug#225680: Fwd: Default pg_autovacuum config glitches