IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Override system date In JCL


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
rahul.nilekar

New User


Joined: 06 Aug 2005
Posts: 5

PostPosted: Wed Sep 12, 2007 3:14 pm
Reply with quote

Is there any parameter in JCL which can used to override system date in the program running in particular step?
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Wed Sep 12, 2007 3:20 pm
Reply with quote

Rahul,

Your post is not clear. Post some more info about your requirment.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Wed Sep 12, 2007 4:24 pm
Reply with quote

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
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Wed Sep 12, 2007 4:54 pm
Reply with quote

No, there is not.
Back to top
View user's profile Send private message
rahul.nilekar

New User


Joined: 06 Aug 2005
Posts: 5

PostPosted: Wed Sep 12, 2007 5:06 pm
Reply with quote

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
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 771
Location: Germany

PostPosted: Wed Sep 12, 2007 5:43 pm
Reply with quote

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
View user's profile Send private message
rahul.nilekar

New User


Joined: 06 Aug 2005
Posts: 5

PostPosted: Thu Sep 13, 2007 10:53 am
Reply with quote

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
View user's profile Send private message
Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Thu Sep 13, 2007 11:28 am
Reply with quote

You can change your COBOL program like
Quote:
ACCEPT WS-DATE
, and then in JCL use SYSIN dd name for the program and pass date.
Back to top
View user's profile Send private message
rahul.nilekar

New User


Joined: 06 Aug 2005
Posts: 5

PostPosted: Thu Sep 13, 2007 11:42 am
Reply with quote

Hi ,
I need to get it done without changing the cobol programs.
Thanks
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Thu Sep 13, 2007 12:09 pm
Reply with quote

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
View user's profile Send private message
Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Thu Sep 13, 2007 12:11 pm
Reply with quote

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
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Thu Sep 13, 2007 12:46 pm
Reply with quote

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
View user's profile Send private message
rahul.nilekar

New User


Joined: 06 Aug 2005
Posts: 5

PostPosted: Fri Sep 14, 2007 12:59 pm
Reply with quote

Thank you all... Hourglass is there at our site
Back to top
View user's profile Send private message
Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Sat Sep 15, 2007 9:11 am
Reply with quote

Quote:
Hourglass is there at our site

Go ahead and use it.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Sysplex System won't IPL at DR site I... All Other Mainframe Topics 2
No new posts Modifying Date Format Using DFSORT DFSORT/ICETOOL 9
No new posts Need to convert date format DFSORT/ICETOOL 20
No new posts How to delete a user's alias from the... JCL & VSAM 11
No new posts Need help to append a date&tsp at... DFSORT/ICETOOL 9
Search our Forums:

Back to Top