Calculation (Aggregation)

You are able to make calculations in field with a numeric data type: You generate an aggregation condition. The result of the calculation is then displayed in a separate results row.

Intermediate Results

Usually all values in a field are used in a calculation during aggregation. You are also able to obtain intermediate results. To do this you have to sort the ALV output and group the rows that you want to use for the intermediate result (see Sorting ).

You are able to make the following settings for aggregations:

Creating, Getting, and Deleting an Aggregation Rule

You are able to create a maximum of one aggregation rule for a field. Aggregation is a property of a field in the ALV output. To create, get, or delete the aggregation rule of a field, use the methods of the interface class IF_SALV_WD_AGGR (implementing class CL_SALV_WD_FIELD).

Function

Method

Get aggregation rule

GET_AGGR_RULE

Create aggregation rule

CREATE_AGGR_RULE

Delete aggregation rule

DELETE_AGGR_RULE

The aggregation rule of a field is represented by an object of the class CL_SALV_WD_AGGR_RULE.