Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Cobol functions

Status
Not open for further replies.

121854

MIS
Aug 2, 2003
60
US
Where can I find the functions available in Cobol? I'm searching for a cobol function that enable me to estimate the number of dates between two dates or the number of months between two dates? Or a function to estimate the julian or gregorian dates.

Your assistance is appreciated.

 
COMPUTE FUNCTION INTEGER-OF-DATE(date2) - FUNCTION INTEGER-OF-DATE(date1)

will give you the number of days between two dates.

FUNCTION DATE-OF-INTEGER(date-number) will give you the gregorian date of a given relative date.

FUNCTION DAY-OF-INTEGER(date-number) will give you the julian date of a given relative date.
 
Which compiler are you using? Have you checked your "Language Reference Manual" for the topic "intrinsic functions"?

Bill Klein
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top