COBOL Manual for TNS and TNS/R Programs

Intrinsic Functions
HP COBOL Manual for TNS and TNS/R Programs522555-006
14-18
DAY-OF-INTEGER Function
DAY-OF-INTEGER Function
DAY-OF-INTEGER, an integer function, converts a date in the Gregorian calendar from
integer date form to Julian date form (YYYYDDD ).
argument
is a positive integer that represents a number of days since December 31, 1600, in
the Gregorian calendar.
The returned value is of the form YYYYDDD, where YYYY represents the year in the
Gregorian calendar and DDD represents the day of that year.
Example 14-10. DAY-OF-INTEGER Function
Code:
DISPLAY FUNCTION DAY-OF-INTEGER (1)
DISPLAY FUNCTION DAY-OF-INTEGER (365)
DISPLAY FUNCTION DAY-OF-INTEGER (36500)
DISPLAY FUNCTION DAY-OF-INTEGER (12345)
DISPLAY FUNCTION DAY-OF-INTEGER (100000)
Output:
1601001
1601365
1700341
1634292
1874289
( )
DAY-OF-INTEGERFUNCTION argument
VST429.vsd