Date limits

All Language Environment date and time services are based on the Gregorian calendar, which has certain limits for the date variables. These limits are:
Starting Lilian Date
The beginning of the valid Lilian date range (day one) is Friday, 15 October 1582, the date the Gregorian calendar was adopted. Lilian dates preceding this date are undefined. In the Lilian date range:
  • Day zero equals 00:00:00 14 October 1582.
  • Day one equals 00:00:00 15 October 1582.

All valid Lilian dates must be after 00:00:00 15 October 1582.

Starting COBOL Integer Date (ANSI COBOL Intrinsic Functions)
The beginning of the COBOL Integer date range according to the COBOL standard is 31 December 1600. COBOL Integer dates preceding this date are undefined. In the COBOL Integer date range:
  • Day zero equals 00:00:00 31 December 1600.
  • Day one equals 00:00:00 01 January 1601.

All valid COBOL Integer dates must be after 00:00:00 01 January 1601.

COBOL has a compiler option, INTDATE, that allows you to get and use Lilian integer dates with COBOL Intrinsic Functions or to use the ANSI starting dates. Use INTDATE(LILIAN) if you want to pass integer dates between programs of different languages and use both Intrinsic Functions and Language Environment callable services to process the integer dates.

End Lilian Date (End COBOL Integer Date)
The end of the Lilian date range, as well as the COBOL Integer date range, is set to 31 December 9999. Lilian dates and COBOL Integer dates following this date are undefined.
Limit of Current Era
The maximum future date you can express in an era system must be within the first 999 years of the current era. Future dates past year 999 of the current era are undefined.