The WHEN-COMPILED function returns the date and time the program was compiled as provided by the system on which the program was compiled. The type of this function is alphanumeric.
|1-4||Four numeric digits of the year in the Gregorian calendar.|
|5-6||Two numeric digits of the month of the year, in the range 01 through 12.|
|7-8||Two numeric digits of the day of the month, in the range 01 through 31.|
|9-10||Two numeric digits of the hours past midnight, in the range of 00 through 23.|
|11-12||Two numeric digits of the minutes past the hour, in the range 00 through 59.|
|13-14||Two numeric digits of the seconds past the minute, in the range 00 through 59.|
|15-16||Two numeric digits of the hundredths of a second past a second, in the range 00 through 99. The value 00 will be returned for all systems|
|17||The character '0'. This field is reserved for future implementation.|
|18-19||The characters '00'. This field is reserved for future implementation.|
|20-21||The characters '00'. This field is reserved for future implementation.|
MOVE FUNCTION WHEN-COMPILED (1:4) TO YEARDATE.