Subject Re: [firebird-support] Date Range
Author Lester Caine
Ann W. Harrison wrote:

> Lester Caine wrote:
>
>>OK date range is quoted as 0100-01-01 to 9999-12-31
>>Is that to the Gregorian calendar, or will there be errors in day counts
>>against the Gregorian calendar?
>
> That's just the count of days using the Gregorian calendar. There's no
> adjustment for the change from the Julian calendar.

That is what I thought - it's just not down in writing ;)

>>Of cause in theory I need dates before the year 0100 - If I can find any
>>ancestors dates from roman times ;)
>
> Arrg. The date data type has one 32 bit word that contains the number
> of days that should be added to the base date to get the desired data.
> If it's negative, it goes backward. The base date is 17 November 1858.
> (Long story omitted as boring and pointless). There are plenty of
> digits to go back earlier than 0100-01-01 and forward beyond 9999. The
> restriction comes from the string representation and the difficulty we
> had in distinguishing between '01/01/01' meaning the first day of the
> modern era and '01/01/01' meaning the first of January 2001. I thought
> you should be able to write '01/01/0001'. Jim thought that leading
> zeros were not significant. We discussed it. I changed the
> documentation.

Thanks for that fills in all the missing detail.
All my dates will be ISO8601 with full years so now I can move to stage
two. A database with all the conversion factors on a country code basis.

--
Lester Caine
-----------------------------
L.S.Caine Electronic Services