Page 1 of 1

How to get all the GDG created in a Day?

Posted: Mon May 11, 2015 8:26 am
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?

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

Posted: Mon May 11, 2015 5:51 pm
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.

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

Posted: Mon May 18, 2015 6:15 pm
by Nitin Kumar
Thanks Robert. But if I don't want to get the data in reverse order what should I do?

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

Posted: Mon May 18, 2015 10:59 pm
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.

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

Posted: Tue May 19, 2015 5:20 pm
by Nitin Kumar
Thanks. I'll work on the suggestion and will get back to you.

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

Posted: Tue Jun 23, 2015 4:27 pm
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.

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

Posted: Sat Jul 23, 2016 11:29 am
by Nitin Kumar
We are not on z/OS v2.1.

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

Posted: Sat Jul 23, 2016 12:38 pm
by enrico-sorichetti
We are not on z/OS v2.1.
any reason to reopen a 1 year old topic?