For M11, the volume comes as 0000001000 and not as 1000 after OVERLAY
i used M10 in count too, however the count gets right justified and not left justified after OVERLAY
Our DFSORT version is Z/OS DFSORT V1R12, so not sure if its related to the version of DFSORT which is not allowing justify to work.
I am not sure if i combined up OVERLAY with TRAILER1, which is not advisable
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
OK, I don't believe them, but if you have no choice...
Code:
//SORTIN DD *
JOINKEYS F1=IN1,FIELDS=(1,1,A),SORTED,NOSEQCK
JOINKEYS F2=IN2,FIELDS=(1,1,A)
JOIN UNPAIRED,ONLY
REFORMAT FIELDS=(F1:1,x,?,F2:1,10)
OPTION COPY
INREC IFTHEN=(WHEN=(x+1,1,CH,EQ,C'1'),
BUILD=(1,x)),
IFTHEN=(WHEN=NONE,
do you stuff to make the trailer))
//JNF1CNTL DD *
OPTION COPY
INREC extend record by one byte, value of X'00'
//JNF2CNTL DD *
INREC BUILD=(X'FF',C0000000001')
SORT FIELDS=(1,1,CH,A)
SUM FIELDS=(2,10,ZD)
OK, I don't believe them, but if you have no choice...
Code:
//SORTIN DD *
JOINKEYS F1=IN1,FIELDS=(1,1,A),SORTED,NOSEQCK
JOINKEYS F2=IN2,FIELDS=(1,1,A)
JOIN UNPAIRED,ONLY
REFORMAT FIELDS=(F1:1,x,?,F2:1,10)
OPTION COPY
INREC IFTHEN=(WHEN=(x+1,1,CH,EQ,C'1'),
BUILD=(1,x)),
IFTHEN=(WHEN=NONE,
do you stuff to make the trailer))
//JNF1CNTL DD *
OPTION COPY
INREC extend record by one byte, value of X'00'
//JNF2CNTL DD *
INREC BUILD=(X'FF',C0000000001')
SORT FIELDS=(1,1,CH,A)
SUM FIELDS=(2,10,ZD)
Ideally, would have liked to have a single step driven process output. But it looks a lot of coding.
I will try both options and see how it could be accommodated.
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
OK. Traditional way. SEQNUM for each record. On each record, further temporarily extend, with your unsequeezed message with the sequence number (use EDIT to get leading blanks, or test thoroughly with PREBLANK :-) ) and then SQZ. It's code and it's time.
There's an example by Arun Raj in the JCL part of the forum of editing the value on a TRAILER1.
Another way is a dummy trailer concatenated to your input. Again SEQNUM per reocrd. When the dummy trailer arrives, take the sequence, format the message and SQZ. Ditch the TRAILER1.
On the receiver, likely some *nix/*nux machine, possibily Windows something, if they already have code to take the filename and use the numeric as data, I really can't believe it is not the work of a moment to have that with leading zeros.