How to get all the GDG created in a Day?

Virtual Storage Access method - ESDS, KSDS, RRDS & LDS. Basic direct access method, Basic sequential -, Queued sequential -, Basic partitioned -, Indexed sequential -, Object - access method.
Post Reply
Nitin Kumar
Registered Member
Posts: 11
Joined: Tue Sep 02, 2014 8:13 pm

How to get all the GDG created in a Day?

Post by Nitin Kumar »

Hi,

There are 8 to 9 gdg of a dataset created for a day in at 8 different timings. I want to get all the versions created for that in a single go instead of getting the latest gdg version everytime. This helps me to ensure that no version is missed for that day. Currently am using the ftp component -shortlist option to get the latest gdg name everytime.

Any suggestion?
User avatar
Robert Sample
Global Moderator
Global Moderator
Posts: 1886
Joined: Fri Jun 28, 2013 1:22 am
Location: Dubuque Iowa
United States of America

Re: How to get all the GDG created in a Day?

Post by Robert Sample »

If your JCL references the GDG base without a generation, all generations will be retrieved. The generations will be retrieved In reverse order -- the latest generation first, then the second-latest, ...
Many sites create daily generations then use SORT once a day to create a daily data set by referencing the GDG base as SORTIN.
Nitin Kumar
Registered Member
Posts: 11
Joined: Tue Sep 02, 2014 8:13 pm

Re: How to get all the GDG created in a Day?

Post by Nitin Kumar »

Thanks Robert. But if I don't want to get the data in reverse order what should I do?
User avatar
Robert Sample
Global Moderator
Global Moderator
Posts: 1886
Joined: Fri Jun 28, 2013 1:22 am
Location: Dubuque Iowa
United States of America

Re: How to get all the GDG created in a Day?

Post by Robert Sample »

One possible approach would be to write a program to scan output from an IDCAMS LISTCAT command and generate the appropriate JCL with the right number of generations, then submit this JCL into the system via INTRDR (the internal reader).

Another possible approach would be to use the GDG base as input to a SORT.

In general, you are either going to have to sort the data or write a program to scan utility output and generate the correct JCL.
Nitin Kumar
Registered Member
Posts: 11
Joined: Tue Sep 02, 2014 8:13 pm

Re: How to get all the GDG created in a Day?

Post by Nitin Kumar »

Thanks. I'll work on the suggestion and will get back to you.
Blackthorn
New Member
Posts: 8
Joined: Tue Jun 23, 2015 4:25 pm

Re: How to get all the GDG created in a Day?

Post by Blackthorn »

Although of course if you're on z/OS v2.1 you can use the GDGORDER parameter so that all generations are NOT processed in reverse order.
Nitin Kumar
Registered Member
Posts: 11
Joined: Tue Sep 02, 2014 8:13 pm

Re: How to get all the GDG created in a Day?

Post by Nitin Kumar »

We are not on z/OS v2.1.
enrico-sorichetti
Global Moderator
Global Moderator
Posts: 825
Joined: Wed Sep 11, 2013 3:57 pm

Re: How to get all the GDG created in a Day?

Post by enrico-sorichetti »

We are not on z/OS v2.1.
any reason to reopen a 1 year old topic?
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort 8-)
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “SMS & VSAM and BDAM, BSAM, QSAM, BPAM, ISAM, OAM.”