Command SUM Foundation
Calculates sums for numeric expressions in the current work area.
SUM <nExpression,...> TO <VarName,...> ;
[FOR <lForCondition>] ;
[WHILE <lWhileCondition>] ;
[NEXT <nCount>] ;
[REST] ;
[ALL]
The command SUM calculates the sum of one or more numeric expressions from the values of the records in the current work area. The range for the summation can be limited by specifying a condition or the number of records. The sum of each numeric expression in <nExpression,...> is assigned to a variable in <VarName,...>.
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.