View previous topic :: View next topic
Author
Message
kishpra New User Joined: 24 May 2010Posts: 92 Location: Pune
Hi All,
I am using the below to merge two ps file records into one ps file using-
Code:
//S05TL EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN1 DD DSN=KK1.OUTPUT.O2,DISP=SHR
//IN2 DD DSN=KK2.OUTPUT.O2,DISP=SHR
//OUT DD DSN=KK3.PROD.OUTPUT,DISP=(NEW,CATLG,DELETE),
// SPACE=(CYL,(50,50),RLSE),LRECL=100,RECFM=FB
//TOOLIN DD *
COPY FROM(IN1) TO(OUT) USING(CTL1)
COPY FROM(IN2) TO(OUT) USING(CTL1)
/*
//CTL1CNTL DD *
OPTION COPY
/*
IN1 : LRECl= 63,BLKSIZE=27972
IN2 : LRECl=100, BLKSIZE=27900
Please assist.
Thanks
Back to top
dick scherrer Moderator Emeritus Joined: 23 Nov 2006Posts: 19244 Location: Inside the Matrix
Hello,
Suggest you look at some of the JOINKEYS examples here in the forum.
Back to top
Rohit Umarjikar Global Moderator Joined: 21 Sep 2010Posts: 3048 Location: NYC,USA
You might be looking for this, also as Dick suggested you can look for JOINKEYS as well.
Code:
//S1 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN1 DD DSN=... input file1 (FB/63)
//IN2 DD DSN=... input file2 (VB/100)
//OUT DD DISP=MOD,DSN=... output file (FB/100)
//TOOLIN DD *
COPY FROM(IN1) TO(OUT)
COPY FROM(IN2) USING(CTL1)
/*
//CTL1CNTL DD *
OUTFIL FNAMES=OUT,VTOF,OUTREC=(5,95,100:X)
Back to top
Skolusu Senior Member Joined: 07 Dec 2007Posts: 2205 Location: San Jose
Rohit Umarjikar wrote:
Code:
//IN2 DD DSN=... input file2 (VB/100)
//CTL1CNTL DD *
OUTFIL FNAMES=OUT,VTOF,OUTREC=(5,95,100:X)
Rohit,
2 minor points.
1. I am not sure as to why you think OP has a VB dataset.
2. Since you overrode the LRECL to 100 in the JCL the contents from the first copy for the dataset with LRECL of 63 will have binary zeroes padded from position 64 thru 100.
Back to top
Rohit Umarjikar Global Moderator Joined: 21 Sep 2010Posts: 3048 Location: NYC,USA
Your are Right , I misunderstood the question.
Due to region down, I can not able to test but I think below should work for the TS, please correct if I missed something.
Code:
//STEP0100 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN1 DD DSN=KK1.OUTPUT.O2,DISP=SHR
//IN2 DD DSN=KK2.OUTPUT.O2,DISP=SHR
//OUT DD DSN=KK3.PROD.OUTPUT,DISP=(MOD,CATLG,DELETE),
// SPACE=(CYL,(50,50),RLSE),LRECL=100,RECFM=FB
//TOOLIN DD *
COPY FROM(IN1) TO(OUT) USING(CTL1)
COPY FROM(IN2) TO(OUT)
//CTL1CNTL DD *
INREC OVERLAY=(100:X)
//*
Back to top
Skolusu Senior Member Joined: 07 Dec 2007Posts: 2205 Location: San Jose
Rohit Umarjikar wrote:
Your are Right , I misunderstood the question.
Due to region down, I can not able to test but I think below should work for the TS, please correct if I missed something.
Code:
LRECL=100,RECFM=FB
//CTL1CNTL DD *
INREC OVERLAY=(100:X)
//*
You really don't need the DCB parameters in JCL as DFSORT is quite capable of calculating based on the input or INREC/OUTREC/OUTFIL control cards. So remove them.
Back to top
Rohit Umarjikar Global Moderator Joined: 21 Sep 2010Posts: 3048 Location: NYC,USA
Code:
//STEP0100 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN1 DD DSN=KK1.OUTPUT.O2,DISP=SHR
//IN2 DD DSN=KK2.OUTPUT.O2,DISP=SHR
//OUT DD DSN=KK3.PROD.OUTPUT,DISP=(MOD,CATLG,DELETE),
// SPACE=(CYL,(50,50),RLSE)
//TOOLIN DD *
COPY FROM(IN1) TO(OUT) USING(CTL1)
COPY FROM(IN2) TO(OUT)
//CTL1CNTL DD *
INREC OVERLAY=(100:X)
//*
Back to top
Please enable JavaScript!