View previous topic :: View next topic
|
Author |
Message |
rahul.nilekar
New User
Joined: 06 Aug 2005 Posts: 5
|
|
|
|
Is there any parameter in JCL which can used to override system date in the program running in particular step? |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
|
|
Rahul,
Your post is not clear. Post some more info about your requirment. |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
rahul.nilekar wrote: |
Is there any parameter in JCL which can used to override system date in the program running in particular step? |
Hi,
Overrides are meant for DD statements.
It's not clear from your post, where do you want to override the date & how? If you show some example, hopefully, some one would be able to answer. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
No, there is not. |
|
Back to top |
|
|
rahul.nilekar
New User
Joined: 06 Aug 2005 Posts: 5
|
|
|
|
Hi,
Please find more info about the problem.
Example:
I am accepting system date in a cobol program like ACCEPT WS-DATE FROM DATE. Now whenever you accept date like this it will return CURRENT SYSTEM DATE into the variable WS-DATE.
But here in this case I want override this SYSTEM DATE with whatever date I will provide thru JCL. So basically the statement ACCEPT WS-DATE FROM DATE should return a date which I have supplied thru JCL.
I hope the problem is a little clear now.
Thanks |
|
Back to top |
|
|
UmeySan
Active Member
Joined: 22 Aug 2006 Posts: 771 Location: Germany
|
|
|
|
Hi rahul.nilekar !
So why not execute the programm with a parm in the JCL where you type that special date.
//SYSTSIN DD *
PROFILE
DSN SYSTEM(DB2T)
RUN PROGRAM(MDL80000) PLAN(GK210307)-
PARM('24.09.1957')
END
Then in your Programm check parm and move this date to your desired field WS-DATE.
Regards, UmeySan |
|
Back to top |
|
|
rahul.nilekar
New User
Joined: 06 Aug 2005 Posts: 5
|
|
|
|
hi,
These are not new programs. These are the existing ones. I just need to test them with different date other than the current date.
Thanks |
|
Back to top |
|
|
Devzee
Active Member
Joined: 20 Jan 2007 Posts: 684 Location: Hollywood
|
|
|
|
You can change your COBOL program like
, and then in JCL use SYSIN dd name for the program and pass date. |
|
Back to top |
|
|
rahul.nilekar
New User
Joined: 06 Aug 2005 Posts: 5
|
|
|
|
Hi ,
I need to get it done without changing the cobol programs.
Thanks |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
|
|
rahul,
Quote: |
I need to get it done without changing the cobol programs. |
Not possible. Either you need to change the program or system date itself (which is not posisble). |
|
Back to top |
|
|
Devzee
Active Member
Joined: 20 Jan 2007 Posts: 684 Location: Hollywood
|
|
|
|
If you dont want to change your code and do this kind of testing,
then you may have to look for some tools.
I remember there were lot of tools available for this kind of date simulation testing during Y2k changes, like Hourglass 2000 .
Check if any available in your site? |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
|
|
Devzee,
Quote: |
I remember there were lot of tools available for this kind of date simulation testing during Y2k changes, like Hourglass 2000 . |
Hour glass effects other programs also running in the region. Need to consider the side effects also. |
|
Back to top |
|
|
rahul.nilekar
New User
Joined: 06 Aug 2005 Posts: 5
|
|
|
|
Thank you all... Hourglass is there at our site |
|
Back to top |
|
|
Devzee
Active Member
Joined: 20 Jan 2007 Posts: 684 Location: Hollywood
|
|
|
|
Quote: |
Hourglass is there at our site |
Go ahead and use it. |
|
Back to top |
|
|
|