Using DFSORT or REXX program

IBM's flagship sort product DFSORT for sorting, merging, copying, data manipulation and reporting. Includes ICETOOL and ICEGENER
samb01
Posts: 431
Joined: Mon Nov 16, 2009 7:24 pm
Skillset: quite good
Referer: by web

Using DFSORT or REXX program

Postby samb01 » Thu Jul 13, 2023 5:54 pm

Hello,
in this file :

Code: Select all


52  : NBR TOT                      
3   : ABA
47  : CDG
0   : QUIT  
0   :                      
15  : NBR UNDER                      
0   : ABA
3   : CDG
0   : QUIT  
0   :        
 


the number in the fisrt line, the number 52 must be equal to the other number of the other three lines ==> 3 + 47 + 0

we don't care about the others following lines

Code: Select all


0   :                      
15  : NBR UNDER                      
0   : ABA
3   : CDG
0   : QUIT  
0   :          
 


I know doing that rexx, but i would like to know if it's possible to use dfsort program ?

User avatar
sergeyken
Posts: 458
Joined: Wed Jul 24, 2019 10:12 pm
Skillset: Assembler, JCL, Utilities, PL/I, C/C++, DB2, SQL, REXX, COBOL, etc. etc. etc.
Referer: Internet search

Re: Using DFSORT or REXX program

Postby sergeyken » Thu Jul 13, 2023 8:47 pm

Remains absolutely unclear: what the final output must be???
Javas and Pythons come and go, but JCL and SORT stay forever.

User avatar
sergeyken
Posts: 458
Joined: Wed Jul 24, 2019 10:12 pm
Skillset: Assembler, JCL, Utilities, PL/I, C/C++, DB2, SQL, REXX, COBOL, etc. etc. etc.
Referer: Internet search

Re: Using DFSORT or REXX program

Postby sergeyken » Fri Jul 14, 2023 7:13 pm

samb01 wrote:Hello,
in this file :

Code: Select all


52  : NBR TOT                      
3   : ABA
47  : CDG
0   : QUIT  
0   :                      
15  : NBR UNDER                      
0   : ABA
3   : CDG
0   : QUIT  
0   :        
 


the number in the fisrt line, the number 52 must be equal to the other number of the other three lines ==> 3 + 47 + 0

we don't care about the others following lines

Code: Select all


0   :                      
15  : NBR UNDER                      
0   : ABA
3   : CDG
0   : QUIT  
0   :          
 


I know doing that rexx, but i would like to know if it's possible to use dfsort program ?

The final attempt to request information.

It seems like your input is a series of "grouped records"; each group begins with group header "nn  : NBR xxxxxxx", and ends with group trailer "0   :   ".
Highly likely, you want to verify, that the "total" amount "nn" of each group does match the sum of partial amounts of all group lines, isn't it?

If you plan to continue keeping silence, please, do not expect any further advice.
Javas and Pythons come and go, but JCL and SORT stay forever.


  • Similar Topics
    Replies
    Views
    Last post