A1110201CITY46000 ---->Header record with length 20 bytes. Record type A (Header).
B41164MMNY735XNJ3562790 ---->record with length length 27 bytes. Record type B (Detail).
B23284LMKY516YNJ4462800 ---->record with length length 27 bytes. Record type B (Detail).
B36374PMJY398RNJ6213567 ---->record with length length 27 bytes. Record type B (Detail).
B37374EQJY318INJ6213567 ---->record with length length 27 bytes. Record type B (Detail).
Z9991301TOTA99999 ---->Header record with length 20 bytes. Record type Z (Trailer).
A1110301CITY46000 ---->Header record with length 20 bytes. Record type A (Header).
B42454TMNY735XNJ3562790 ---->record with length length 27 bytes. Record type B (Detail).
B26266SMKY516YNJ4462800 ---->record with length length 27 bytes. Record type B (Detail).
Z9991301TOTA99999 ---->Header record with length 20 bytes. Record type Z (Trailer).
B41164MMNY735XNJ3562790 ---->record with length length 27 bytes. Record type B (Detail).
B23284LMKY516YNJ4462800 ---->record with length length 27 bytes. Record type B (Detail).
B36374PMJY398RNJ6213567 ---->record with length length 27 bytes. Record type B (Detail).
B37374EQJY318INJ6213567 ---->record with length length 27 bytes. Record type B (Detail).
Z9991301TOTA99999 ---->Header record with length 20 bytes. Record type Z (Trailer).
A1110301CITY46000 ---->Header record with length 20 bytes. Record type A (Header).
B42454TMNY735XNJ3562790 ---->record with length length 27 bytes. Record type B (Detail).
B26266SMKY516YNJ4462800 ---->record with length length 27 bytes. Record type B (Detail).
Z9991301TOTA99999 ---->Header record with length 20 bytes. Record type Z (Trailer).
This is one physical file containing several logical files.
First postion indicates the record type.
Query:
I want to prefix 020 for A record type in the position 1-3
and prefix 026 for B record type in the position 1-3
and prefix 020 for Z record type in the position 1-3.
And want to copy the data to another VB file which has A record of 20bytes, B record of 26 bytes and Z of 20 bytes.
We can do this using cobol code, but I would like to know if its possible with any JCL utility or any other tool.
Thanks,
Giri
Coded for you