by Vicky007 » Wed Sep 29, 2010 8:24 pm
Hi Frank,
I used the code you suggested to Sharmiladevi and wrote the below code. It worked good and I got the desired output. However, when I tried for records more than 50 to be joined(ie, number of records b/w 2 '@'), I'm getting error. Because am using more than 50 'WITH' keyword in SPLICE operator.
Do you have any other suggestion to address this issue? Below is the piece of code that I used assuming I need to combine 50 records into one.
//TOOLIN DD *
SPLICE FROM(IN) TO(OUT) ON(30001,8,ZD) KEEPNODUPS WITHANY -
WITH(81,80) WITH(161,80) WITH(241,80) WITH(321,80) WITH(401,80) -
"
"
"
WITH(4001,80) USING(CTL1)
/*
//CTL1CNTL DD *
OPTION COPY
INREC IFOUTLEN=30008,
IFTHEN=(WHEN=GROUP,BEGIN=(1,1,CH,EQ,C'@'),
PUSH=(30001:ID=8,30009:SEQ=5)),
IFTHEN=(WHEN=(30009,5,ZD,EQ,2),BUILD=(81:1,80,30001:30001,8)),
IFTHEN=(WHEN=(30009,5,ZD,EQ,3),BUILD=(161:1,80,30001:30001,8)),
"
"
"
IFTHEN=(WHEN=(30009,5,ZD,EQ,51),BUILD=(4001:1,80,30001:30001,8))
OUTFIL FNAMES=OUT,BUILD=(1,30000)
/*
Please provide ur suggestion.
Thanks in advance!
Vicky SK