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
 

 

to make one file using 2 files

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
comp_ashok

New User


Joined: 30 Nov 2007
Posts: 15
Location: India

PostPosted: Thu Dec 13, 2007 12:32 pm    Post subject: to make one file using 2 files
Reply with quote

Hi all,

My requirement is:

input1: fb, lrec=7

2222600
3333700
4444300

input2 : fb, lrec=8

11117000
22220100
33331200


output file:fb ,lrec=11

11110007000
22226000100
33337001200
44443000000

initial 4 bytes are same, next 3 from input file 1 , next 4 from input file2
if initial 4 bytes are not present in that file thyen place zeros.
Back to top
View user's profile Send private message

krisprems

Active Member


Joined: 27 Nov 2006
Posts: 649
Location: India

PostPosted: Thu Dec 13, 2007 1:14 pm    Post subject:
Reply with quote

Code:
//*******************************************************             
//STEP001  EXEC PGM=ICETOOL                                           
//TOOLMSG  DD SYSOUT=*                                               
//DFSMSG   DD SYSOUT=*                                               
//IN1      DD *                                                       
2222600                                                               
3333700                                                               
4444300                                                               
/*                                                                   
//IN2      DD *                                                       
11117000                                                             
22220100                                                             
33331200                                                             
/*                                                                   
//TMP1     DD DSN=&&TEMP1,DISP=(MOD,PASS),SPACE=(TRK,(5,5)),UNIT=SYSDA
//BOTH     DD SYSOUT=*                                               
//TOOLIN   DD *                                                       
 COPY FROM(IN1)  TO(TMP1) USING(CP01)                                 
 COPY FROM(IN2)  TO(TMP1) USING(CP02)                                 
 SPLICE FROM(TMP1) TO(BOTH) ON(1,4,CH) WITH(8,4) -
   KEEPNODUPS USING(CP03)                         
/*                                               
//CP01CNTL DD   *                                 
  OUTREC BUILD=(1,7,8:4C'0',12:C'11')             
/*                                               
//CP02CNTL DD   *                                 
  OUTREC BUILD=(1,4,5:3C'0',8:5,4,12:C'22')       
/*                                               
//CP03CNTL DD   *                                 
  OUTFIL FNAMES=BOTH,BUILD=(1,11)                 
/*                                               


OUT:
Code:
11110007000
22226000100
33337001200
44443000000
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SORTJOIN - Copy Matched and Unmatched... Steve Ironmonger DFSORT/ICETOOL 5 Tue Jan 17, 2017 4:26 pm
No new posts Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm
No new posts High CPU consumption Job using IAM fi... aswinir JCL & VSAM 15 Thu Dec 01, 2016 8:28 pm
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm


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