View previous topic :: View next topic
|
Author |
Message |
Raymond Sachs
New User
Joined: 13 Dec 2007 Posts: 45 Location: USA
|
|
|
|
Dear Listers,
When trying to execute the following:
//STEP0100 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SYMNAMES DD *
MYDAY,S'&WDAY'
//SORTIN DD DSN=PUBLIC.TEST.INPUT.FILE01,DISP=SHR
//SORTOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=COPY
INREC OVERLAY=(20:MYDAY)
//*
I get a wrong "Day of the Week". I ran on Monday and it gives TUE. I can vouch it returned the right day earlier. Any suggestions?
Code: |
SYNCSORT LICENSED FOR CPU SERIAL NUMBER 52655, MODEL 2097 710 LIC
SYSIN :
SORT FIELDS=COPY
INREC OVERLAY=(20:MYDAY)
DATA DICTIONARY SYMBOLS SUBSTITUTED :
SORT FIELDS=COPY
INREC OVERLAY=(20:C'TUE')
WER276B SYSDIAG= 78243, 2292019, 2292019, 5332800
WER164B 8,608K BYTES OF VIRTUAL STORAGE AVAILABLE, MAX REQUESTED,
WER164B 0 BYTES RESERVE REQUESTED, 2,240K BYTES USED
WER146B 20K BYTES OF EMERGENCY SPACE ALLOCATED
WER108I SORTIN : RECFM=FB ; LRECL= 80; BLKSIZE= 27920
WER257I INREC RECORD LENGTH = 80
WER110I SORTOUT : RECFM=FB ; LRECL= 80; BLKSIZE= 27920
WER410B 7,848K BYTES OF VIRTUAL STORAGE AVAILABLE ABOVE THE 16MEG LINE,
WER410B 0 BYTES RESERVE REQUESTED, 2,116K BYTES USED
WER211B SYNCSMF CALLED BY SYNCSORT; RC=0000
WER449I SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE
WER416B SORTIN : EXCP'S=1,UNIT=3390,DEV=E524,CHP=(7A7B7879,2),VOL=DVL117
WER416B BSAM WAS USED FOR SORTOUT
WER054I RCD IN 1, OUT 1
WER169I RELEASE 1.3 BATCH 0506 TPF LEVEL 2.1
WER052I END SYNCSORT - KC02628S,STEP0100,,DIAG=AE00,7104,822C,004E,E6D2,488B,0
2010-11-280 TUE
******************************** BOTTOM OF DATA ********************************
|
|
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
If your site is using UMT instead of local time, accessing the current day would give different results for several hours of the UMT offset. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
One reason why I always use the local date/time variables, i.e. LWDAY. |
|
Back to top |
|
|
Raymond Sachs
New User
Joined: 13 Dec 2007 Posts: 45 Location: USA
|
|
|
|
Quote: |
One reason why I always use the local date/time variables, i.e. LWDAY |
So should I change the INREC OVERLAY=(20:MYDAY) to INREC OVERLAY=(20:LWDAY)? I am not sure if I am missing something. |
|
Back to top |
|
|
Raymond Sachs
New User
Joined: 13 Dec 2007 Posts: 45 Location: USA
|
|
|
|
Quote: |
If your site is using UMT instead of local time, accessing the current day would give different results for several hours of the UMT offset.
|
How do I check that ? How do I check what format of time my site is using? |
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
Raymond Sachs wrote: |
So should I change the INREC OVERLAY=(20:MYDAY) to INREC OVERLAY=(20:LWDAY)? I am not sure if I am missing something. |
Raymond,
Inorder to access local date, change the symbol &WDAY to &LWDAY |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Instead of S'&WDAY' try S'&LWDAY'.
I have no connection to my "docs" tonight, so i haven't verified this.
Quote: |
How do I check what format of time my site is using? |
Whoever supports the product should be able to tell you. |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
Back to top |
|
|
Raymond Sachs
New User
Joined: 13 Dec 2007 Posts: 45 Location: USA
|
|
|
|
Thanks all for your help. It worked. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Good to hear it is working - thank you for letting us know
d |
|
Back to top |
|
|
|