From: | Thomas Lockhart <lockhart(at)alumni(dot)caltech(dot)edu> |
---|---|
To: | José Soares <jose(at)sferacarta(dot)com> |
Cc: | hackers <pgsql-hackers(at)postgreSQL(dot)org>, general <pgsql-general(at)postgreSQL(dot)org> |
Subject: | Re: [HACKERS] Gregorian Calendar |
Date: | 1999-04-13 14:48:49 |
Message-ID: | 37135951.88FDB948@alumni.caltech.edu |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
> I have a question about dates.
> The Gregorian reform of calendar skiped 10 days on Oct, 1582.
> This reform was accepted by Great Britain and Dominions (including
> what is now the USA) only in 1752.
> If I insert a date that doesn't exist PostgreSQL accepts it.
> Should it be considered normal ?
As Peter says, this is tricky.
Date conventions before the 19th century make for interesting reading,
but are not imho consistant enough to warrant coding into a date/time
handler.
As you probably have noticed, we use Julian date calculations for our
date/time support. They have the nice property of correctly
predicting/calculating any date more recent than something like 4013BC
to far into the future, using the assumption that the length of the
year is 365.25 days. This is a very recently adopted convention
(sometime in the 1800s I had thought, but perhaps it was during the
same "reform" in 1752).
I've toyed with the idea of implementing a Chinese dynastic calendar,
since it seems to be more predictable than historical European
calendars.
- Tom
--
Thomas Lockhart lockhart(at)alumni(dot)caltech(dot)edu
South Pasadena, California
From | Date | Subject | |
---|---|---|---|
Next Message | De Leersnijder Frederic | 1999-04-13 16:16:57 | Opening two databases at the same time? |
Previous Message | Thomas Lockhart | 1999-04-13 14:29:16 | Re: [HACKERS] Re: [GENERAL] leap day bug after 1901 |