Previous Topic: Date Conversion RoutinesNext Topic: CA TLMS Internal Date Format


Date Calculation Routines

Several forms of the TLMDATE macro are provided to perform ADD TO DATE and SUBTRACT FROM DATE operations, and to calculate the days difference between two dates. This series of macros only works with CA TLMS internal dates. For these date calculation routines, the following parameters must be defined:

TODATE=

Defines the CA TLMS internal date to be added to, or is the HIGH DATE when calculating the difference between two dates.

FRDATE=

Defines the CA TLMS internal date to be subtracted from, or is the LOW DATE when calculating the difference between two dates.

LOAD

Specifies whether the DATE module is to be loaded or which LPA version is to be used.

DAYS=

Indicates the number of days to be added to or subtracted from a date, or points to the field to receive the result when calculating the difference between two dates.

YEARS=

Indicates the number of years to be added to or subtracted from a date.

RESULT=

Points to the field to receive the date resulting from an add or subtract operation. RESULT is always a CA TLMS date, internal packed 4 bytes.