[prev in list] [next in list] [prev in thread] [next in thread] 

List:       postgresql-admin
Subject:    Re: [BUGS] [ADMIN] Date Return must be As per Natural Calander
From:       "Ross J. Reedstrom" <reedstrm () rice ! edu>
Date:       2003-02-25 17:16:00
[Download RAW message or body]

On Mon, Feb 24, 2003 at 11:06:38PM -0500, Tom Lane wrote:
> Robert Treat <xzilla@users.sourceforge.net> writes:
> > I guess adding 1 day to 1752-09-02 should give us 1752-09-14, but your
> > right, it gives us 1752-09-03.
> 
> As was pointed out at length just recently, the transition from Julian
> to Gregorian calendars happened at different times in different places.
> So the above claim is only correct for some places.
> 
> The conclusion from the previous discussion was that our existing
> behavior (extrapolate Gregorian rules backwards indefinitely) is as
> defensible as anything else that would be likely to get coded.

To quote SQL1992:

  4.5.3  Operations involving datetimes and intervals

  [...]
  Arithmetic operations involving items of type datetime or inter-
  val obey the natural rules associated with dates and times and
  yield valid datetime or interval results according to the Gregorian
  calendar.

Ross

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic