Page 1 of 1

Doudt in GDG...

PostPosted: Mon Nov 01, 2010 10:17 am
by Purushoth
In my JCL, In step1 I'll gonna create a new generation dataset for that I gave GDG Name(+1). In step2 and Step3 I wanna to use same dataset created by step1? What number i should give to refer that dataset?(here, step1 executed successfully) and i need valid reasion too?

Re: Doudt in GDG...

PostPosted: Mon Nov 01, 2010 10:30 am
by dick scherrer
Hello and welcome to the forum,

Use +1 to reference the newly created gdg generation within that job.

and i need valid reasion too?
What does this mean? What kind of reason might be needed?

Re: Doudt in GDG...

PostPosted: Mon Nov 01, 2010 10:41 am
by NicC
When creating and using a GDG within a job it is usually best to create the dataset as a workfile and use that in subsequent steps. At the end of the job, or usage of the dataset within the job, copy the dataset to its GDG name +1. This avoids job restart problems.

Re: Doudt in GDG...

PostPosted: Mon Nov 01, 2010 10:56 am
by steve-myers
NicC's idea is excellent, though it is not always a good idea, especially if the data set is large.

The naming rule for GDG data sets is that within a job, each relative generation always refers to the same data set. In other words, if STEP1 creates relative generation +1, use +1 in a subsequent step to refer to the same data set as was created in STEP1.

Re: Doudt in GDG...

PostPosted: Mon Nov 01, 2010 11:01 am
by dick scherrer
Hello,

If the job runs from a PROCedure (and many/most do), the reletive generation can be a symbolic parameter that has a default of +1 and for a restart zero can be used. Makes restarts much easier. . .

Re: Doudt in GDG...

PostPosted: Mon Nov 01, 2010 1:12 pm
by NicC
Makes restarts much easier if you do not have to change ANYTHING :D At one place we had 2 systems of ensuring that a job restarted at the correct step. Workfile deleteion, database restores all automatic.

Re: Doudt in GDG...

PostPosted: Mon Nov 01, 2010 2:46 pm
by Purushoth
:) Thanks a lot for ur suggestion abt ma question. I am Purushoth from India..may i knw from whom i got the answers and where u from?

Re: Doudt in GDG...

PostPosted: Mon Nov 01, 2010 2:54 pm
by enrico-sorichetti
..may i knw from whom i got the answers and where u from?

will it make any difference in understanding the replies and judging their usefulness for Your environment ?
there is no reason to invade anybody' s privacy with personal questions!

the preferences on the userids used on public forums range from ...
a completely obfuscated nickname to a full name/last_name

Re: Doudt in GDG...

PostPosted: Wed Nov 03, 2010 12:29 am
by Phrzby Phil
Control-M automatically handles the generation# on restart.