IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Copy data from one input file to multiple output files


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
hnharish

New User


Joined: 30 Aug 2005
Posts: 23

PostPosted: Tue Jul 21, 2009 6:26 pm
Reply with quote

I have requirement in which i need to copy same data from the input file to multiple output file in one JCL step.All the output files will have the same data.Please provide the sample JCL step.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Tue Jul 21, 2009 6:35 pm
Reply with quote

What have you tried yourself already? There's lots of ways to do this but since this is not a do-it-for-you forum, you'll need to give us more and not just ask for the code.
Back to top
View user's profile Send private message
hnharish

New User


Joined: 30 Aug 2005
Posts: 23

PostPosted: Tue Jul 21, 2009 6:43 pm
Reply with quote

I know that it can be done using IEBGENER or MULTIGEN utility but here we can copy data from one input file into one output file.My requirement was to copy from one input file to multiple output file in one step.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Tue Jul 21, 2009 6:52 pm
Reply with quote

You can use DFSORT or ICETOOL
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Tue Jul 21, 2009 8:48 pm
Reply with quote

hnharish,

You can use a DFSORT job like the following to do what you asked for:

Code:

//S1    EXEC  PGM=SORT
//SYSOUT    DD  SYSOUT=*
//SORTIN DD DSN=...  input file
//OUT1 DD DSN=...  output file1
//OUT2 DD DSN=...  output file1
  ...
//SYSIN    DD    *
  OPTION COPY
  OUTFIL FNAMES=(OUT1,OUT2,...)
/*


Alternatively, you can use a DFSORT/ICETOOL job like the following:

Code:

//S2    EXEC  PGM=ICETOOL
//TOOLMSG   DD  SYSOUT=*
//DFSMSG    DD  SYSOUT=*
//IN DD DSN=...  input file
//OUT1 DD DSN=...  output file1
//OUT2 DD DSN=...  output file1
  ...
//TOOLIN   DD    *
COPY FROM(IN) TO(OUT1,OUT2,...)
/*


If you're not familiar with DFSORT and DFSORT's ICETOOL, I'd suggest reading through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from:

www.ibm.com/support/docview.wss?rs=0&uid=isg3T7000080
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 0
No new posts Compare 2 files(F1 & F2) and writ... JCL & VSAM 8
No new posts TRIM everything from input, output co... DFSORT/ICETOOL 1
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Store the data for fixed length COBOL Programming 1
Search our Forums:

Back to Top