View previous topic :: View next topic
Author
Message
Hervey Martinez New User Joined: 12 Jul 2016Posts: 6 Location: United States
I'm processing the hsm miglog dataset and trying to put something together to process records with errors.
I am looking at the ARC0734I records that have "RC= 20, REASON= 98" and the file in error is in the subsequent record.
I'm merging both of these records into an output file for subsequent processing and getting garbage on the output and have looked at all the parms and not sure how to correct the error;
Input file:
first record:
Code:
ARC0734I ACTION=MIGRATE FRVOL=HSMVOL TOVOL=...... TRACKS= 1 RC= 20, REASON= 98, AGE= 54
second record:
Code:
DSN=ABC.EXN.ZZ69310.JM69353.RFPQERR.G0575V00
On the output file, I get:
Code:
ABC.EXN.ZZ69310.JM69353.RFPQERR.G0575V00 RC= 20, REASON= 98, AGE=2 54
The "2" on the age should be a blank.
My sort parms:
Code:
SORT FIELDS=COPY
INREC IFTHEN=(WHEN=GROUP,
BEGIN=(2,23,CH,EQ,C'ARC0734I ATCION=MIGRATE',
AND,70,7,CH,EQ,C'RC= 20'),
RECORDS=2,PUSH=(52:70,31,79:SEQ=1))
OUTFILE INCLUDE=(79,1,ZD,EQ,2),
BUILD=(2:7,44,
47:52,31)
code' d
Back to top
RahulG31 Active User Joined: 20 Dec 2014Posts: 446 Location: USA
Your problem may be this as you are overwriting position 79 with SEQ
Code:
PUSH=(52:70,31,79:SEQ=1))
Back to top
magesh23586 Active User Joined: 06 Jul 2009Posts: 213 Location: Chennai
Try below code
Code:
SORT FIELDS=COPY
INREC IFTHEN=(WHEN=GROUP,
BEGIN=(2,23,CH,EQ,C'ARC0734I ATCION=MIGRATE',
AND,70,7,CH,EQ,C'RC= 20'),
RECORDS=2,PUSH=(52:70,31,83:SEQ=1))
OUTFILE INCLUDE=(83,1,ZD,EQ,2),
BUILD=(2:7,44,
47:52,31)
Back to top
Rohit Umarjikar Global Moderator Joined: 21 Sep 2010Posts: 3051 Location: NYC,USA
magesh23586, Isn't it same as RahulG31?
Back to top
magesh23586 Active User Joined: 06 Jul 2009Posts: 213 Location: Chennai
Rohit Umarjikar wrote:
magesh23586, Isn't it same as RahulG31?
Yes Rohit,
RahulG31 provided the root cause.
I gave the resolution.
Back to top
Please enable JavaScript!