Re: BUG #11883: Year 1500 not treated as leap year when it was a leap year

From: Bruce Hunsaker <hunsakerbn(at)ldschurch(dot)org>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Bruce Hunsaker <hunsakerbn(at)ldschurch(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Magnus Hagander <magnus(at)hagander(dot)net>, <hunsakerbn(at)familysearch(dot)org>, pgsql-bugs <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: BUG #11883: Year 1500 not treated as leap year when it was a leap year
Date: 2014-11-07 15:16:11
Message-ID: 20141107151611.GD4482@gr8.dev
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On 07 Nov 14 02 02, Bruce Momjian wrote:
> On Thu, Nov 6, 2014 at 07:29:49AM -0700, Bruce Hunsaker wrote:
> > > I have applied the attached C comment to document why we use the
> > > Gregorian calendar for pre-1582 years.
> >
> > Thanks everyone for the response. I guess the bottom line for us
> > is that if we want to store dates before 1582, we may not want
> > to use date or timestamp columns for that data, particularly if
> > the dates are from a Julian calendar.
>
> Yeah, the big problem is that there is no way to store leap days for
> years like 1500. The only good part is that the Gregorian calendar is
> very good at keeping the calendar aligned with the seasons.

Just to add some additional background, We were migrating data from
an Oracle DB when we hit this. Oracle's dates are Julian based
and range from Jan 1, 4712 BCE to Dec 31 9999 CE. So Feb 29, 1500
is a valid date in an Oracle Date type (Julian day 2268992). So I
wonder what the rules might be to convert a Julian date to a
'proleptic Gregorian' date (pre 1582) and vice versa?

--
Bruce Hunsaker

NOTICE: This email message is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message.

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Bruce Hunsaker 2014-11-07 15:30:53 Re: BUG #11883: Year 1500 not treated as leap year when it was a leap year
Previous Message Tom Lane 2014-11-07 15:06:26 Re: BUG #11883: Year 1500 not treated as leap year when it was a leap year