Page 1 of 1

sort files with record count !!!

Posted: Fri Mar 10, 2017 2:30 am
by balaryan
Hi All,

I am sorting the input file and segregating to four output files based on some conditions along with record count. Then separate the record count from each files for validation purpose.

Right now, I am getting the desired results in two steps.

Step 1: from ONE input file to FOUR output files (trailer record hold record count) using SORT with INCLUDE condition.

Step 2: Using ICETOOL, to get the record count separately into flat files.
SUBSET FROM(IN1) TO(OUT1) KEEP INPUT LAST
SUBSET FROM(IN2) TO(OUT2) KEEP INPUT LAST
SUBSET FROM(IN3) TO(OUT3) KEEP INPUT LAST
SUBSET FROM(IN4) TO(OUT4) KEEP INPUT LAST

I am not sure whether it was doable in the single step using ICETOOL to split the records into four different files along with record count and have separate datasets holding only record count.

Any hint would be appreciated.