I'm getting an unexpected result from my sort.
//STEP010 EXEC PGM=SORT
//SORTJNF1 DD *
1000
1001
1003
1005
//SORTJNF2 DD *
1000
1003
1007
//SORTOF01 DD SYSOUT=*
//SORTOF02 DD SYSOUT=*
//SORTOF03 DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SYSIN DD *
JOINKEYS FILES=F1,FIELDS=(1,4,A)
JOINKEYS FILES=F2,FIELDS=(1,4,A)
JOIN UNPAIRED,F1,F2
REFORMAT FIELDS=(?,F1:1,4,F2:1,4)
SORT FIELDS=COPY
OUTFIL FILES=01,INCLUDE=(1,1,CH,EQ,C'B'),BUILD=(1:2,4)
OUTFIL FILES=02,INCLUDE=(1,1,CH,EQ,C'1'),BUILD=(1:2,4)
OUTFIL FILES=03,INCLUDE=(1,1,CH,EQ,C'2'),BUILD=(1:2,4)
/*
The output for SORTOF01 is as expected: 1000 and 1003
The output for SORTOF02 is as expected: 1001 and 1005
However the output for SORTOF03 is a blank row instead of 1007
If I tweak the BUILD to 1:1,5 I can see the row starts with 2 so it looks to be working, just no output
And thoughts?
Thanks in advance
Cheers