Integer date limits

Integer dates are the number of days from some point in the past. These can be useful for easily comparing and sorting dates, and they need only 4 bytes in stored data. However, there is a multiplicity of starting dates, depending on the source of the date, which means the same date obtained from different sources has different integer values. To get a correct compare or sort, you must be certain that the date data involved were derived from the same start date.

Integer date starting points
CICS, MVS, DB2
PL/I *
C
COBOL
Language Environment
start with Jan 1, 1900
start with Oct 15, 1582
start with Jan 1, 1970
start with Jan 1, 1601
start with Oct 15, 1582
Solution for COBOL:
Use COBOL
for MVS & VM (or COBOL for OS/390 & VM) install option
  • INTDATE(LILIAN) or INTDATE(ANSI)
  • Use INTDATE(LILIAN) to get Lang.Env. Lilian dates from intrinsic functions so the same start date is being used.

* Support in workstation compilers only.

©1997 IBM Corporation next