Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Jcl to compare GDG version creation date with system date

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
ankit garg

New User


Joined: 18 Dec 2007
Posts: 1
Location: India

PostPosted: Thu Apr 30, 2009 7:45 pm    Post subject: Jcl to compare GDG version creation date with system date
Reply with quote

Hi

Currently I am using GDG version created by source system(monthly once) in my monthly job.
I need to have a check whether the latest version avaliable is not the one which is created in last month(reason might be that source system has not created the current month version by the time my job kicks off)
Could anyone help me with JCL to implement the check.
Back to top
View user's profile Send private message

Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7996
Location: Bellevue, IA

PostPosted: Thu Apr 30, 2009 7:53 pm    Post subject:
Reply with quote

Create a file that contains the last GDG processed.

Use IDCAMS LISTCAT to get current generations of the GDG.
Use a program to parse the LISTCAT output to find the latest generation.

Use a program to compare the generation in the file against the output of the LISTCAT parse to see if they're equal. If not, write the latest generation to the file and proceed.

What you're wanting to do requires at least one program -- it cannot be done purely with JCL, which does nothing but execute programs anyway.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Fri May 01, 2009 12:59 am    Post subject:
Reply with quote

And also, please use the correct terminology. Versions and Generations are both valid terms when dealing with GDS.

If YOU do not understand the correct terminology, how the hell do you expect us to really know what you mean.

Please get it right next time !!!!!!!!!!!!!!!!!!!!!
Back to top
View user's profile Send private message
RAIN YE

New User


Joined: 06 May 2009
Posts: 7
Location: China

PostPosted: Thu May 07, 2009 5:16 am    Post subject:
Reply with quote

Hi I agree with Robert's processing steps, and I think these can be done by 'pure batch', if icetool is defined as part of it. It can do the find string job as well as matching.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Date and time format in CICS Chandru3183 CICS 2 Sat Mar 18, 2017 12:46 pm
No new posts How to get current date -1 and curren... murali.andaluri DFSORT/ICETOOL 3 Wed Mar 08, 2017 2:09 pm
No new posts GDG version number PANDU1 JCL & VSAM 4 Sat Mar 04, 2017 8:28 pm
No new posts Overlay the system date Danielle.Filteau SYNCSORT 4 Fri Mar 03, 2017 1:16 am
No new posts Checking Current date vickey_dw DFSORT/ICETOOL 1 Wed Feb 08, 2017 11:14 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us