Subject: | |
From: | |
Reply To: | VANCE,JEFF (HP-Cupertino,ex1) |
Date: | Mon, 29 Nov 1999 10:44:52 -0700 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
FWIW, the below scheme for creating a month-day-year date has at least
one risk: the HPDATE value could change after the HPMONTH value was
referenced. Or, the HPYEAR value could change after HPDATE was
referenced, depending on exactly when this job was executing.
On 6.0 systems you can use the new predefined CI variable HPYYYYMMDD
which is guaranteed to not have these month/year boundary problems.
Alternatively, you can check your resulting date after it is
constructed, e.g.:
setvar month HPMONTH
setvar date HPDATE
setvar year HPYYYY
setvar curr_day "!month/!date/!year"
if year <> HPYEAR or month <> HPMONTH then
# year or month boundary -- recompute curr_day
setvar curr_day "!hpmonth/!hpdate/!hpyyyy"
endif
...
> JCL WWA:SETVAR CURR_DAY "!HPMONTH"+"/"+"!HPDATE"+"/"+"!HPYEAR"
regards,
Jeff Vance, CSY
|
|
|