Re: timestamp patch to extend legal range of dates.
От | John Cochran |
---|---|
Тема | Re: timestamp patch to extend legal range of dates. |
Дата | |
Msg-id | 200302051201.h15C1Keq042860@smof.fiawol.org обсуждение исходный текст |
Ответ на | Re: timestamp patch to extend legal range of dates. (Oliver Elphick <olly@lfix.co.uk>) |
Ответы |
Re: timestamp patch to extend legal range of dates.
|
Список | pgsql-patches |
[snip...] > I got my data from > http://serendipity.magnet.ch/hermetic/cal_stud/cal_art.htm > which also talks about proleptic calendars; that is, the current > calendar is projected backwards (or the Julian calendar is projected > forwards), so that there are no breaks in the sequence of dates. > > Does the SQL standard define what calendar it is using? My copy of Date > & Cannan: 'SQL -- The Standard Handbook' says: > > "YEAR - Valid values: 0001 to 9999. This permits the specification of > dates prior to the invention of the Gregorian calendar and assumes that > the rules of the Gregorian calendar can be applied retrospectively." > > So I suggest we should use the Gregorian proleptic calendar as the > default. > > Example: England Italy Proleptic > Gregorian > > 15 Sep 1752 15 Sep 1752 15 Sep 1752 > 1 Sep 1752 12 Sep 1752 12 Sep 1752 > 25 Mar 1751 5 Apr 1751 5 Apr 1751 > 24 Mar 1750 4 Apr 1751 4 Apr 1751 > 6 Oct 1582 15 Oct 1582 15 Oct 1582 > 5 Oct 1582 5 Oct 1582 14 Oct 1582 > 24 Mar 1581 24 Mar 1582 3 Apr 1582 > [snip...] Point taken. I withdraw my patch. However, I'm going to examine date2j() and j2date() functions a bit closer and see if I can restructure them to eliminate the overflow problems they have. I would still like for those functions to be capable of dealing with the full range of available numbers.
В списке pgsql-patches по дате отправления: