Creating a PDS with Multiple members



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

Creating a PDS with Multiple members

Postby jasand » Tue May 25, 2010 4:16 pm

hi,

Can you help me with the JCL to create a PDS with multiple empty members (say A1, A2, ....A200)
Note: I want to create the PDS and the 200 members in a single step

I tried with the following code to create empty members for an already existing PDS. But I was not able to create more than one member in a single step
/*JOBPARM S=*                                             
//STEP01   EXEC PGM=IEBGENER                             
//SYSPRINT DD   SYSOUT=*                                 
//SYSUT1   DD   *                                         
/*                                                       
//SYSUT2   DD   DISP=SHR,DSN=AAAA.BBBB.CCCC(NEWJCL) 
//SYSIN    DD   DUMMY                                     
//SYSOUT   DD   SYSOUT=*                                 
//*                                                       
jasand
 
Posts: 11
Joined: Fri Mar 12, 2010 5:41 pm
Has thanked: 1 time
Been thanked: 0 time

Re: Creating a PDS with Multiple members

Postby Robert Sample » Tue May 25, 2010 4:38 pm

I'm not sure you can create the PDS and all the members in a single step.

If you allocate the PDS, you can then use IDCAMS to create up to 250 members (more or less) in a single step:
//STEP1    EXEC PGM=IDCAMS,REGION=6M
//SYSPRINT DD   SYSOUT=*
//IN1      DD   DUMMY
//OUT001   DD   DISP=SHR,DSN=TTSSRS0.IBMMF.EMPTY.PDS(A0000001)
//OUT002   DD   DISP=SHR,DSN=TTSSRS0.IBMMF.EMPTY.PDS(A0000002)
//OUT003   DD   DISP=SHR,DSN=TTSSRS0.IBMMF.EMPTY.PDS(A0000003)
//OUT004   DD   DISP=SHR,DSN=TTSSRS0.IBMMF.EMPTY.PDS(A0000004)
//OUT005   DD   DISP=SHR,DSN=TTSSRS0.IBMMF.EMPTY.PDS(A0000005)
//SYSIN    DD   *
  REPRO IFILE(IN1) OFILE(OUT001)
  REPRO IFILE(IN1) OFILE(OUT002)
  REPRO IFILE(IN1) OFILE(OUT003)
  REPRO IFILE(IN1) OFILE(OUT004)
  REPRO IFILE(IN1) OFILE(OUT005)
This JCL creates five empty members in a PDS.

More to the point, what on earth is the business requirement driving such a bizarre need?
Robert Sample
Global moderator
 
Posts: 3720
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times

Re: Creating a PDS with Multiple members

Postby MrSpock » Tue May 25, 2010 9:25 pm

I would've opted to use IEBUPDTE if the process met the requirements.
User avatar
MrSpock
Global moderator
 
Posts: 809
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 4 times

Re: Creating a PDS with Multiple members

Postby jasand » Wed May 26, 2010 12:41 pm

Thanks for the reply.
It worked
jasand
 
Posts: 11
Joined: Fri Mar 12, 2010 5:41 pm
Has thanked: 1 time
Been thanked: 0 time


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post