Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Split a Dataset into multiple Members

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Compuware & Other Tools
View previous topic :: :: View next topic  
Author Message
yianis

New User


Joined: 14 Aug 2006
Posts: 45

PostPosted: Fri Nov 16, 2007 8:49 pm    Post subject: Split a Dataset into multiple Members
Reply with quote

I have a job (DFSORT) for now and I read in a Dataset File and want to split it up into multiple output Members.

Here is a sample of my job:
Code:

//JS00200  EXEC PGM=ICEMAN                                             
//SYSOUT   DD SYSOUT=*                                             
//SORTIN   DD DSN=STG.MTL.C4.R01.ESM.BK.WORKFLOW.PROD(0),DISP=SHR   
//*                                                                 
//OUT001   DD DSN=JTZANET.ESM.SYSINESM(MTL003),DISP=SHR             
//OUT002   DD DSN=JTZANET.ESM.SYSINESM(MTL004),DISP=SHR             
//OUT003   DD DSN=JTZANET.ESM.SYSINESM(MTL005),DISP=SHR         
//SYSIN    DD *                                                     
  OPTION COPY                                                       
  OUTFIL INCLUDE=(01,03,CH,EQ,C'003'),FNAMES=OUT001                 
  OUTFIL INCLUDE=(01,03,CH,EQ,C'004'),FNAMES=OUT002                 
  OUTFIL INCLUDE=(01,03,CH,EQ,C'005'),FNAMES=OUT003                 


Now, I don't care if it's DFSORT or IDCAMS or FILEAID.

but I'm getting an Abend B14 and cannot do it....
Back to top
View user's profile Send private message

Douglas Wilder

Active User


Joined: 28 Nov 2006
Posts: 305
Location: Deerfield IL

PostPosted: Fri Nov 16, 2007 9:03 pm    Post subject:
Reply with quote

Code:
 B14                                                                       
                                                                           
 Explanation:  The error occurred during processing of a CLOSE macro       
 instruction for a partitioned data set opened for output to a member. This
 system completion code is accompanied by message IEC217I. Refer to the     
 explanation of message IEC217I for complete information about the task     
 that was ended and for an explanation of the return code (rc in the       
 message text) in register 15.                                             

What rc code did you get?
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Fri Nov 16, 2007 9:10 pm    Post subject: Reply to: Split a Dataset into multiple Members
Reply with quote

The job seems fine. The B14 makes me suspect a problem with the PDS (not enough space, not enough directory blocks, etc.).
Back to top
View user's profile Send private message
yianis

New User


Joined: 14 Aug 2006
Posts: 45

PostPosted: Fri Nov 16, 2007 9:18 pm    Post subject: Reply to: Split a Dataset into multiple Members
Reply with quote

Actually, i increased the space etc.. and the error is IEC143I 213-30
It's because I am trying to update/create multiple members in the dataset and is causing a problem

It won't allow me to have multiple output members within a single step.

I don't want to split this job into n-multiple steps with each step having a single input and single output...I'd prefer to do it in 1 step but it seems you cannot do this...
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Fri Nov 16, 2007 9:21 pm    Post subject: Reply to: Split a Dataset into multiple Members
Reply with quote

I forgot, you're right, you can't do that. Maybe you'll find your answer using FileAid, unless a combination of SORT and IEBUPDTE would work for you?

I'll move this post over to the FileAid forum.
Back to top
View user's profile Send private message
yianis

New User


Joined: 14 Aug 2006
Posts: 45

PostPosted: Fri Nov 16, 2007 9:32 pm    Post subject: Reply to: Split a Dataset into multiple Members
Reply with quote

Yeah I know.. that's why I had it originally posted in the JCL forum...
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Fri Nov 16, 2007 10:22 pm    Post subject: Re: Split a Dataset into multiple Members
Reply with quote

yianis wrote:
I have a job (DFSORT) for now and I read in a Dataset File and want to split it up into multiple output Members.

Here is a sample of my job:
Code:

//JS00200  EXEC PGM=ICEMAN                                             
//SYSOUT   DD SYSOUT=*                                             
//SORTIN   DD DSN=STG.MTL.C4.R01.ESM.BK.WORKFLOW.PROD(0),DISP=SHR   
//*                                                                 
//OUT001   DD DSN=JTZANET.ESM.SYSINESM(MTL003),DISP=SHR             
//OUT002   DD DSN=JTZANET.ESM.SYSINESM(MTL004),DISP=SHR             
//OUT003   DD DSN=JTZANET.ESM.SYSINESM(MTL005),DISP=SHR         
//SYSIN    DD *                                                     
  OPTION COPY                                                       
  OUTFIL INCLUDE=(01,03,CH,EQ,C'003'),FNAMES=OUT001                 
  OUTFIL INCLUDE=(01,03,CH,EQ,C'004'),FNAMES=OUT002                 
  OUTFIL INCLUDE=(01,03,CH,EQ,C'005'),FNAMES=OUT003                 


Now, I don't care if it's DFSORT or IDCAMS or FILEAID.

but I'm getting an Abend B14 and cannot do it....


Make the OUT001, OUT002, and OUT003 files temp files and add 3 iebgener steps to copy them into the JTZANET.ESM.SYSINESM pds.
Back to top
View user's profile Send private message
yianis

New User


Joined: 14 Aug 2006
Posts: 45

PostPosted: Fri Nov 16, 2007 11:39 pm    Post subject: Reply to: Split a Dataset into multiple Members
Reply with quote

I could do the same thing with the DFSORT (multiple steps), but I am trying to avoid the creation of multiple steps and would like to do it in a single step. The actual jobb will probably have 100 files to create and I want to avoid 100 steps...Thx for the suggestion
Back to top
View user's profile Send private message
Douglas Wilder

Active User


Joined: 28 Nov 2006
Posts: 305
Location: Deerfield IL

PostPosted: Fri Nov 16, 2007 11:56 pm    Post subject:
Reply with quote

You could use separate PS datasets (with the last node different).
Or use a PDSE instead of a PDS.
Back to top
View user's profile Send private message
lcmontanez

New User


Joined: 19 Jun 2007
Posts: 50
Location: Chicago

PostPosted: Sat Nov 17, 2007 12:32 am    Post subject:
Reply with quote

you can also create a 1 step proc that is run 100 times.....
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Tue Nov 20, 2007 7:25 am    Post subject: Reply to: Split a Dataset into multiple Members
Reply with quote

Hi,
you can get away with it in 2 steps.

See below

Gerry [/code]
//STEP0001 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD *
003
004
005
//*
//OUT001 DD DSN=&&O001,DISP=(,PASS,DELETE),UNIT=SYSDA,SPACE=(TRK,(1))
//OUT002 DD DSN=&&O002,DISP=(,PASS,DELETE),UNIT=SYSDA,SPACE=(TRK,(1))
//OUT003 DD DSN=&&O003,DISP=(,PASS,DELETE),UNIT=SYSDA,SPACE=(TRK,(1))
//SYSIN DD *
OPTION COPY
OUTFIL INCLUDE=(01,03,CH,EQ,C'003'),FNAMES=OUT001
OUTFIL INCLUDE=(01,03,CH,EQ,C'004'),FNAMES=OUT002
OUTFIL INCLUDE=(01,03,CH,EQ,C'005'),FNAMES=OUT003
//*
//**********************************************************************
//*
//REPRO EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//FILEIN1 DD DSN=&&O001,DISP=(OLD,DELETE)
//FILEIN2 DD DSN=&&O002,DISP=(OLD,DELETE)
//FILEIN3 DD DSN=&&O003,DISP=(OLD,DELETE)
/*
//FILEOUT1 DD DSN=PDS(A),DISP=SHR
//FILEOUT2 DD DSN=PDS(B),DISP=SHR
//FILEOUT3 DD DSN=PDS(C),DISP=SHR
//SYSIN DD *
REPRO INFILE(FILEIN1) OUTFILE(FILEOUT1)
REPRO INFILE(FILEIN2) OUTFILE(FILEOUT2)
REPRO INFILE(FILEIN3) OUTFILE(FILEOUT3)
Back to top
View user's profile Send private message
yianis

New User


Joined: 14 Aug 2006
Posts: 45

PostPosted: Tue Nov 20, 2007 9:45 pm    Post subject: Reply to: Split a Dataset into multiple Members
Reply with quote

Thanks... I actually created a dataset with the type as LIBRARY (i.e. PDSE) and it worked...I will also keep your suggestion in mind too.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Compuware & Other Tools All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Want to pull the job log into a Mainf... Jishu Mukherjee Compuware & Other Tools 9 Tue Mar 21, 2017 4:48 pm
No new posts To display values of multiple rows in... vinu78 DB2 2 Thu Mar 09, 2017 1:20 pm
No new posts Copying Panvalet members to PDS LOGESHWARAN K CA Products 4 Mon Mar 06, 2017 10:45 am
No new posts JCL to get submitted once dataset has... vinu78 JCL & VSAM 17 Thu Feb 16, 2017 7:32 am
No new posts Calling procedure with multiple entri... steve-myers PL/I & Assembler 5 Fri Jan 27, 2017 3:33 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us