very good mood on
here is a snippet
****** ***************************** Top of Data ******************************
- - - - - - - - - - - - - - - - - - - 3 Line(s) not Displayed
000004 //S1 EXEC PGM=SORT
000005 //SYSPRINT DD SYSOUT=*
000006 //SYSOUT DD SYSOUT=*
000007 //SORTIN DD *
000008 01; 0,450;USD;DOLLARS;
000009 02;1.152,23; 55,70; 80,37;
000010 02;1.265,45; 55,60; 80,00;
000011 02;1.143,78; 52,10; 80,00;
000012 02;1.056,23; 58,04; 80,00;
000013 02;1.678,21; 55,50; 80,14;
000014 02;1.535,28; 57,00; 80,00;
000015 02;1.826,74; 56,00; 80,16;
000016 02; 355,28; 28,80; 30,00;
000017 02;1.120,00; 58,80; 80,00;
000018 02; 55,13; 8,00; 15,00;
000019 02; 261,45; 28,10; 30,17;
000020 02; 257,26; 29,13; 30,00;
000021 02; 53,12; 8,00; 15,00;
000022 02; 258,54; 29,00; 30,00;
000023 02;1.532,15; 53,10; 80,00;
000024 02; 0,00; 0,20; 0,00;
000025 03; 60;
000026 01; 0,123;KLD;DARSEKS;
000027 02;1.152,23; 55,70; 80,37;
000028 02;1.265,45; 55,60; 80,00;
000029 02;1.143,78; 52,10; 80,00;
000030 02;1.056,23; 58,04; 80,00;
000031 02;1.678,21; 55,50; 80,14;
000032 02;1.535,28; 57,00; 80,00;
000033 02;1.826,74; 56,00; 80,16;
000034 02; 355,28; 28,80; 30,00;
000035 02;1.120,00; 58,80; 80,00;
000036 02; 55,13; 8,00; 15,00;
000037 02; 261,45; 28,10; 30,17;
000038 02; 257,26; 29,13; 30,00;
000039 02; 53,12; 8,00; 15,00;
000040 02; 258,54; 29,00; 30,00;
000041 02;1.532,15; 53,10; 80,00;
000042 02; 0,00; 0,20; 0,00;
000043 03; 60;
000044 //SORTOUT DD SYSOUT=*
000045 //SYSIN DD *
000046 OPTION COPY
000047 INREC IFTHEN=(WHEN=GROUP,BEGIN=(1,2,CH,EQ,C'01'),
000048 PUSH=(61:04,07)),
000049 IFTHEN=(WHEN=(01,02,CH,EQ,C'02'),
000050 OVERLAY=(61:61,07,UFF,M11,LENGTH=8,
000051 71:04,08,UFF,M11,LENGTH=8,
000052 81:13,08,UFF,M11,LENGTH=8,
000053 91:22,08,UFF,M11,LENGTH=8,
000054 31:((61,08,ZD,MUL,71,08,ZD),ADD,+500),DIV,+1000,EDIT=(I.IIT,TT),
000055 C';',
000056 ((61,08,ZD,MUL,81,08,ZD),ADD,+500),DIV,+1000,EDIT=(I.IIT,TT),
000057 C';',
000058 ((61,08,ZD,MUL,91,08,ZD),ADD,+500),DIV,+1000,EDIT=(I.IIT,TT),
000059 C';'))
000060 OUTREC BUILD=(1,60,80:X)
****** **************************** Bottom of Data ****************************
here is the result
********************************* TOP OF DATA **********************************
01; 0,450;USD;DOLLARS;
02;1.152,23; 55,70; 80,37; 518,50; 25,07; 36,17;
02;1.265,45; 55,60; 80,00; 569,45; 25,02; 36,00;
02;1.143,78; 52,10; 80,00; 514,70; 23,45; 36,00;
02;1.056,23; 58,04; 80,00; 475,30; 26,12; 36,00;
02;1.678,21; 55,50; 80,14; 755,19; 24,98; 36,06;
02;1.535,28; 57,00; 80,00; 690,88; 25,65; 36,00;
02;1.826,74; 56,00; 80,16; 822,03; 25,20; 36,07;
02; 355,28; 28,80; 30,00; 159,88; 12,96; 13,50;
02;1.120,00; 58,80; 80,00; 504,00; 26,46; 36,00;
02; 55,13; 8,00; 15,00; 24,81; 3,60; 6,75;
02; 261,45; 28,10; 30,17; 117,65; 12,65; 13,58;
02; 257,26; 29,13; 30,00; 115,77; 13,11; 13,50;
02; 53,12; 8,00; 15,00; 23,90; 3,60; 6,75;
02; 258,54; 29,00; 30,00; 116,34; 13,05; 13,50;
02;1.532,15; 53,10; 80,00; 689,47; 23,90; 36,00;
02; 0,00; 0,20; 0,00; 0,00; 0,09; 0,00;
03; 60;
01; 0,123;KLD;DARSEKS;
02;1.152,23; 55,70; 80,37; 141,72; 6,85; 9,89;
02;1.265,45; 55,60; 80,00; 155,65; 6,84; 9,84;
02;1.143,78; 52,10; 80,00; 140,68; 6,41; 9,84;
02;1.056,23; 58,04; 80,00; 129,92; 7,14; 9,84;
02;1.678,21; 55,50; 80,14; 206,42; 6,83; 9,86;
02;1.535,28; 57,00; 80,00; 188,84; 7,01; 9,84;
02;1.826,74; 56,00; 80,16; 224,69; 6,89; 9,86;
02; 355,28; 28,80; 30,00; 43,70; 3,54; 3,69;
02;1.120,00; 58,80; 80,00; 137,76; 7,23; 9,84;
02; 55,13; 8,00; 15,00; 6,78; 0,98; 1,85;
02; 261,45; 28,10; 30,17; 32,16; 3,46; 3,71;
02; 257,26; 29,13; 30,00; 31,64; 3,58; 3,69;
02; 53,12; 8,00; 15,00; 6,53; 0,98; 1,85;
02; 258,54; 29,00; 30,00; 31,80; 3,57; 3,69;
02;1.532,15; 53,10; 80,00; 188,45; 6,53; 9,84;
02; 0,00; 0,20; 0,00; 0,00; 0,02; 0,00;
03; 60;
******************************** BOTTOM OF DATA ********************************
some starting values of Your results example are different from those in the input
the data part of the first column of the computed values is 9 bytes instead of 8
some computations are just plain wrong ... 0.20 * 0.450 ==> 0.09 NOT 0.04
( probably because You did everything by hand )
PS ...
not just good mood, but TERRIFIC GOOD MOOD