FTP and GDG version



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

FTP and GDG version

Postby mathew28 » Tue Oct 20, 2009 11:13 am

In my JCL, The latest version is created in step 1 using the FTP pgm.
I need to use the latest version FTPed in the step 1 in the step 2. My doubt is what is the version that I should use to
refer the FTPed file in the step 1 of the same JCL.

Let my base GDG File name be F33555.FAILED.FILE

So, please tell if I have to use F33555.FAILED.FILE(+1) or F33555.FAILED.FILE(0) in the step 2.

If we are creating the file F33555.FAILED.FILE(+1) using the IDCAMS utility in the step 1, we can use the same file by refering to F33555.FAILED.FILE(+1) in step 2.
But in my case, we are FTPing the file with SYSOUT DD SYSOUT=* in step 1. So, what is version that I should use to refer to the FTPed file in the next steps.
mathew28
 
Posts: 30
Joined: Tue Oct 20, 2009 11:06 am
Has thanked: 0 time
Been thanked: 0 time

Re: FTP and GDG version

 

Re: FTP and GDG version

Postby expat » Tue Oct 20, 2009 11:32 am

/RANT ON

When talking about GDS it is important to use the correct terminology, as both version and generation are both valid in terms of a GDS.

It is a well known fact that only one version of a GDS may exist at any one time, however, multiple generations may exist together.

Please learn and use the correct terminology when posting, as using the wrong term can cause confusion and possibly delay a resolution to your problem

/RANT OFF

So what have you tried to do, and what happened
expat
 
Posts: 382
Joined: Sat Jun 09, 2007 3:21 pm
Has thanked: 0 time
Been thanked: 1 time

Re: FTP and GDG version

Postby MrSpock » Tue Oct 20, 2009 12:47 pm

When you submit a job that has one or more DD statements that refer to a new relative generation number, the system places an enque on the GDG base and resolves your relative generation specification, i.e. F33555.FAILED.FILE(+1) into the actual absolute generation, such as F33555.FAILED.FILE.G0001V00 for the entire length of the job. So, in your case, if the DD statement of your FTP step catalogs a new relative generation as F33555.FAILED.FILE(+1), and if you want to refer to that same dataset in a subsequent step, then that step, and any other step, will also have to specify F33555.FAILED.FILE(+1).
User avatar
MrSpock
Global moderator
 
Posts: 810
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 2 times

Re: FTP and GDG version

Postby mathew28 » Tue Oct 20, 2009 2:57 pm

Thanks Mr. Spock.

But please confirm if there is in any difference between the creation of a new generation of GDG using FTP and IDCAMS.

As I mentioned earlier, the File is not created using IDCAMS utility like in the below code:

//STEP20 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD DUMMY
//FILEOUT DD DSN=F33555.FAILED.FILE(+1),
// DISP=(,CATLG,DELETE),
// MGMTCLAS=TEST1M,
// SPACE=(TRK,(100,15),RLSE),
// DCB=(BLKSIZE=6400,LRECL=132,RECFM=VB)



But it is created using FTP as shown below:
Output File will be: F33555.FAILED.FILE(+1)

//STEP010 EXEC PGM=FTP,REGION=010R,
// PARM='(EXIT',COND=(0,LT)
//INPUT DD DSN=S010AS1.S010AS3.CCLIB,DISP=SHR
//OUTPUT DD SYSOUT=A
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*


So, please confirm whether usage of F33555.FAILED.FILE(+1) in the other steps in the same job will refer to the latest version FTPed file in STEP010. Since the DD statement in my FTP step does not have F33555.FAILED.FILE(+1)

Thanks again,
mathew28
 
Posts: 30
Joined: Tue Oct 20, 2009 11:06 am
Has thanked: 0 time
Been thanked: 0 time

Re: FTP and GDG version

Postby MrSpock » Tue Oct 20, 2009 4:44 pm

Fine, but where is the similar DD statement in STEP10 where you specify the catalog of the +1 generation?

//STEP010 EXEC PGM=FTP,REGION=010R,
// PARM='(EXIT',COND=(0,LT)
//INPUT DD DSN=S010AS1.S010AS3.CCLIB,DISP=SHR
//OUTPUT DD SYSOUT=A
//FILEOUT DD DSN=F33555.FAILED.FILE(+1),
// DISP=(,CATLG,DELETE),
// MGMTCLAS=TEST1M,
// SPACE=(TRK,(100,15),RLSE),
// LRECL=132,RECFM=VB
User avatar
MrSpock
Global moderator
 
Posts: 810
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 2 times

Re: FTP and GDG version

Postby nnina » Tue Oct 20, 2009 4:47 pm

you can use same generation means (+1) to your step2 or any step but in the same job.
nnina
 
Posts: 3
Joined: Mon Oct 12, 2009 9:43 am
Has thanked: 0 time
Been thanked: 0 time

Re: FTP and GDG version

Postby mathew28 » Tue Oct 20, 2009 6:07 pm

@ MrSpock

The +1 generation is mentioned inside DSN (INPUT DD DSN=S010AS1.S010AS3.CCLIB), i.e. the file FTPed is having the +1 generation file name. The DSN=S010AS1.S010AS3.CCLIB contains the Get step to F33555.FAILED.FILE(+1).

The new catalog is not specified explicitly in the JCL. So, my doubt.

My assumption is that in //STEP010, after the FTP, the latest version F33555.FAILED.FILE(+1), say F33555.FAILED.FILE.G00V200 is created by the time we come to step 2.
So, i feel that in Step 2 the FTPed file in Step 1 should be referred with F33555.FAILED.FILE(0) and NOT F33555.FAILED.FILE(+1).

Hope you have understood the situation now. Please reply..
mathew28
 
Posts: 30
Joined: Tue Oct 20, 2009 11:06 am
Has thanked: 0 time
Been thanked: 0 time


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post