Re: timestamp arithmetic (a possible bug?) - Mailing list pgsql-bugs

From Stephan Szabo
Subject Re: timestamp arithmetic (a possible bug?)
Date
Msg-id 20040702070659.G64673@megazone.bigpanda.com
Whole thread Raw
In response to Re: timestamp arithmetic (a possible bug?)  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: timestamp arithmetic (a possible bug?)
List pgsql-bugs
On Fri, 2 Jul 2004, Tom Lane wrote:

> Ilir Gashi <I.Gashi@city.ac.uk> writes:
> > I saw this behaviour in PostgreSQL 7.2. (Once again, I know this is an old
> > release but I do not have a newer version installed, and I am only using
> > the server for research purposes). If you execute the following statement
>
> > SELECT (CAST('01.01.2004 10:01:00' AS TIMESTAMP) - CAST('01.01.2004
> > 10:00:00' AS TIMESTAMP)) + CAST('01.01.2004 10:00:00' AS TIMESTAMP);
>
> (There is a timestamp + interval operator, so you could make it work by
> flipping around the outer addition.)

Should we be providing an interval + timestamp operator as well since it
looks like the spec implies both orderings should work?

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: Grant Update (Possible bug)?
Next
From: Tom Lane
Date:
Subject: Re: Possible bug?