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

Copy two different length files


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

Active User


Joined: 02 May 2005
Posts: 128
Location: UK

PostPosted: Thu Mar 18, 2010 6:22 pm
Reply with quote

I have input1 file FB,RL=5
RECORD in input file are like this

ABCDE
SSSSS
DDDDD
NNNNN

I have second file FB,RL=10
Which have RECORD

RRRRRRRRRR
TTTTTTTTTTT

I want to copy all records of Input1 & input2 file to a variable length file of RL=4 . so the output will be
ABCDE
SSSSS
DDDDD
NNNNN
ABCDE
SSSSS
DDDDD
NNNNN
RRRRRRRRRR
TTTTTTTTTTT
Back to top
View user's profile Send private message
shr_amar
Warnings : 2

Active User


Joined: 02 May 2005
Posts: 128
Location: UK

PostPosted: Thu Mar 18, 2010 6:35 pm
Reply with quote

Please ignore previous post that has some errors:-


I have input1 file FB,RL=5
RECORD in input file are like this

ABCDE
SSSSS
DDDDD
NNNNN

I have second file FB,RL=10
Which have RECORD

RRRRRRRRRR
TTTTTTTTTTT

I want to copy all records of Input1 & input2 file to a variable length file of RL=14 . so the output will be

ABCDE
SSSSS
DDDDD
NNNNN
RRRRRRRRRR
TTTTTTTTTTT
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Thu Mar 18, 2010 10:14 pm
Reply with quote

shr_amar,

The following DFSORT/ICETOOL JCL will give you the desired results

Code:

//STEP0100 EXEC PGM=ICETOOL             
//TOOLMSG  DD SYSOUT=*                   
//DFSMSG   DD SYSOUT=*                   
//FB05     DD DSN=Your 05 byte FB file,DISP=SHR
//FB10     DD DSN=Your 10 byte FB file,DISP=SHR
//OUTV     DD DSN=your output 14 byte VB file,
//            DISP=(MOD,CATLG,DELETE),   
//            UNIT=SYSDA,               
//            SPACE=(CYL,(X,Y),RLSE)     
//TOOLIN   DD *                         
  COPY FROM(FB05) USING(CTL1)           
  COPY FROM(FB10) USING(CTL1)           
//CTL1CNTL DD *                         
  INREC OVERLAY=(14:X)                   
  OUTFIL FNAMES=OUTV,FTOV,BUILD=(1,10)   
//*
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 Store the data for fixed length COBOL Programming 1
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts PARSE Syntax for not fix length word ... JCL & VSAM 7
No new posts Write line by line from two files DFSORT/ICETOOL 7
No new posts Compare only first records of the fil... SYNCSORT 7
Search our Forums:

Back to Top