Hi All,
Really sorry i went through numerous posts but cannot fit in my requirement.
My requirement :
Input file doesn't come with correct number of detail records which is present as Trailer record count. Need to calculate the number of details records and replace it as Trailer record count.
Input file :
AB 001 2012-07-07 ------------ Header
AB 100 2012-07-07 ------------ Detail record
AB 200 2012-07-07 ------------ Detail record
AB 002 2012-07-07 0000000005 ---------- Trailer record
Output file :
AB 001 2012-07-07 ------------ Header
AB 100 2012-07-07 ------------ Detail record
AB 200 2012-07-07 ------------ Detail record
AB 002 2012-07-07 0000000002 ---------- Trailer record
Thanks in advance