Purpose
Returns yesterday's date in the format requested.
Syntax
►►─┬─ YESTERDAY ──┬─ ( date-format ) ─────────────────────────────────────────►◄ └─ YESTERDAYX ─┘
Parameters
Invokes the yesterday function. YESTERDAYX returns a date that contains the century portion of the year.
Specifies the output date format. Date-format can be expressed using:
Date-format can be:
Example 1
In the following example, the yesterday function is used to display yesterday's date in the calendar format (where today is March 17, 1997).
Statement:
MOVE YESTERDAY('C') TO WK-RESULT.
Returned value: 031697
Example 2
This example uses YESTERDAYX to return a date containing the century:
Statement:
MOVE YESTERDAYX('C') TO WK-RESULT.
Returned value: 03161997
|
Copyright © 2014 CA.
All rights reserved.
|
|