I have a variable length VSAM file (record length vary from 95 to 5387 depending on a counter value occurring in position 40). The counter is of data type Binary. I am checking the value for 04 through 99, depending on the counter value I have to blank out the values from position 208. I have the sort card as follows:

SORT FIELDS=COPY

INREC IFTHEN=(WHEN=(44,2,BI,EQ,04),BUILD=(1:1,207,208:0054X)),

IFTHEN=(WHEN=(44,2,BI,EQ,05),BUILD=(1:1,207,208:0108X)),

IFTHEN=(WHEN=(44,2,BI,EQ,06),BUILD=(1:1,207,208:0162X)),

IFTHEN=(WHEN=(44,2,BI,EQ,07),BUILD=(1:1,207,208:0216X)),

IFTHEN=(WHEN=(44,2,BI,EQ,08),BUILD=(1:1,207,208:0270X)),

IFTHEN=(WHEN=(44,2,BI,EQ,09),BUILD=(1:1,207,208:0324X)),

IFTHEN=(WHEN=(44,2,BI,EQ,10),BUILD=(1:1,207,208:0378X)),

IFTHEN=(WHEN=(44,2,BI,EQ,11),BUILD=(1:1,207,208:0432X)),

IFTHEN=(WHEN=(44,2,BI,EQ,12),BUILD=(1:1,207,208:0486X)),

IFTHEN=(WHEN=(44,2,BI,EQ,13),BUILD=(1:1,207,208:0540X)),

IFTHEN=(WHEN=(44,2,BI,EQ,14),BUILD=(1:1,207,208:0594X)),

....

....

....

IFTHEN=(WHEN=(44,2,BI,EQ,78),BUILD=(1:1,207,208:4050X)),

IFTHEN=(WHEN=(44,2,BI,EQ,79),BUILD=(1:1,207,208:4104X)),

IFTHEN=(WHEN=(44,2,BI,EQ,80),BUILD=(1:1,207,208:4158X)),

IFTHEN=(WHEN=(44,2,BI,EQ,81),BUILD=(1:1,207,208:4212X)),

....

....

....

IFTHEN=(WHEN=(44,2,BI,EQ,98),BUILD=(1:1,207,208:5130X)),

IFTHEN=(WHEN=(44,2,BI,EQ,99),BUILD=(1:1,207,208:5184X))

When I execute the above sort card, I am getting the below error.

IFTHEN=(WHEN=(44,2,BI,EQ,78),BUILD=(1:1,207,208:4050X)),

IFTHEN=(WHEN=(44,2,BI,EQ,79),BUILD=(1:1,207,208:4104X)),

$

ICE111A E REFORMATTING FIELD ERROR

IFTHEN=(WHEN=(44,2,BI,EQ,80),BUILD=(1:1,207,208:4158X)),

$

ICE005A 0 BLANK NEEDED IN COLUMN 1 OR OPERATION NOT DEFINED CORRECTLY

IFTHEN=(WHEN=(44,2,BI,EQ,81),BUILD=(1:1,207,208:4212X)),

$

ICE005A 0 BLANK NEEDED IN COLUMN 1 OR OPERATION NOT DEFINED CORRECTLY

IFTHEN=(WHEN=(44,2,BI,EQ,82),BUILD=(1:1,207,208:4266X)),

$

Is it because I cannot add more than 4095 spaces? I am not getting the error when the number of spaces added is less than 4096. Can DFSORT experts help me find out why the sort card fails? Please let me know if any more details are required.

Thanks

Prasanna G.