I am facing a problem as below.Please let me know if you have any solution.
I have a i/p file on which i am using a non IBM utility to scramble the data available between column 6 to 13(for security purpose) .The technique is working fine but in the process the trailor is also getting scrambled which we do not want.
The utility has no option to direct the scrambling for particular record types.
Please let me know if any other utility can be used after the scramble step which will read the original trailor and write it back to the scrambled trailor.
Joined: 20 Jan 2007 Posts: 684 Location: Hollywood
Trailer - Are you referring to trailer record (last record) from the original file?
If you want to copy trailer record from the original file to after scrambed file, then you can write SORT step to select only the trailer record and append it to the after scrambled file.
yes trailor means last record of the file.But in that case the scrambled trailor will also be present and the original trailor will append after that.How can i remove the scrambled trailor?Please provide the sort sysin detail .
Thanks for your quick response.
Please look into the code below which will sort the record between header and trailer it wont disturb those records and sort inbetween records. i am not sure what utility ur using. try similar kind of logic in ur code.
//S1 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=
//SORTOUT DD DSN=... output file
Put special key of '1' in 81 for data records.
For header record, put special key of '' in 81.
For trailer record, put special key of '9' in 81.
Sort by special key ('', '1' or '9') and then regular key.
Remove special key.
By using a special key of '0' for the header