View previous topic :: View next topic
|
Author |
Message |
kkxlnc
New User
Joined: 12 Jun 2005 Posts: 44 Location: Boston
|
|
|
|
I have a specific requirement to populate the out dsn with the previous month and year while I NDM a report to a Unix Server. I know how to use the &DATE=%SUBDATE1 parameter and populate the current date but I have not been able to figure out how to populate the previous month and year.
Say, I run the job on 1st of March 09. The out DSN should have 0902 (YYMM - the month should be the previous month). It should also be able to handle the year part if its run on 1st Jan.)
SIGNON USERID=(XX) ESF=YES
SUBMIT PROC=NDMCTC -
&DSN1='user.KK.report' -
&DSN2='user.KK.report.Yyymm'
&DSN2='user.KK.report.Y0902'
SIGNOFF
The other way I can think of if writing a cobol program to create a dynamic CTC every month and then pass this ctc to the NDM JCL. But any suggestions to handle this issue directly through NDM would be very helpful. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
I think that writing a COBOL program might be a little bit of overkill, but yes, you'll have to use some program logic. |
|
Back to top |
|
|
kkxlnc
New User
Joined: 12 Jun 2005 Posts: 44 Location: Boston
|
|
|
|
Yes, a COBOL would be an overhead to the whole process. Hence have left it as the last option if nothing else works. But I would really like to see it happening directly in the NDM job. Still trying to figure out. Any suggestions are welcome. |
|
Back to top |
|
|
|