by richagoyal » Mon Jun 14, 2010 3:02 pm
hi ,
Fields 1 , 3,4 are not always 1 character . field2 is of length 10 byte comp with v999 so it is always xx.xxx . record format of input is VB .
INREC IFTHEN=(WHEN=(5,3,CH,EQ,C'001'),
PARSE=(%01=(ENDBEFR=C',',FIXLEN=3),
%02=(ENDBEFR=C'-',FIXLEN=4),
%03=(ENDBEFR=C'-',FIXLEN=2),
%04=(ENDBEFR=C',',FIXLEN=2),
%05=(ENDBEFR=C',',FIXLEN=19)),
BUILD=(1,4,%01,%02,%03,%04,%05,1336C' ')),
IFTHEN=(WHEN=(5,3,CH,EQ,C'002'),
PARSE=(%10=(ENDBEFR=C',',FIXLEN=3),
%11=(ENDBEFR=C',',FIXLEN=8),
%70=(ENDBEFR=C',',FIXLEN=10),
%12=(ENDBEFR=C',',FIXLEN=10),
%13=(ENDBEFR=C',',FIXLEN=10),
%14=(ENDBEFR=C',',FIXLEN=19),
%15=(ENDBEFR=C',',FIXLEN=19),
%16=(ENDBEFR=C',',FIXLEN=40),
%17=(ENDBEFR=C',',FIXLEN=19),
%18=(ENDBEFR=C',',FIXLEN=19),
%19=(ENDBEFR=C',',FIXLEN=10)),
BUILD=(1,4,%10,%11,%12,%13,
%14,SFF,TO=PD,LENGTH=10,
%15,SFF,TO=PD,LENGTH=10,
%16,
%17,SFF,TO=PD,LENGTH=10,
%18,SFF,TO=PD,LENGTH=10,
%19,SFF,TO=PD,LENGTH=5))
even if 1 , 2,3 field is of more than 1 character i am able to manage by defining its length , but not able to round off field2 (%19).