I have a VB file of 80 bytes and I have to sort this file based on 1-3 bytes(key field) and then sum next 12 bytes for similar key values and subtract 4 from it and store the output in a VB file.
I have generated a JCl which sorts the file and calculates the sum of next 12 byte for similar key values. PFB the sort cord:
Here I have used 5 because its an VB file and in VB file 1-4 bytes are reserved.
Input file data:
Output file data:
Here sum is 12 bytes long.
Now as I have to subtract 4 from the sum I have changed my sort card as given below:
On using above sort card I got unexpected result:
The sum is now 15 bytes long instead of 12 bytes.
Can anybody please tell me why on using SUB keyword the size increases from 12 to 15bytes.