SAP INT TABLE AT ABEXA



Get Example source ABAP code based on a different SAP table
  



Group Level Processing
This example demonstrates group level processing in internal tables.

ABAP_SOURCE_CODE
DEMO CL_DEMO_INT_TBLS_AT

ABAP_DESCRIPTION
A hashed table itab is created, filled with six lines, and sorted by the primary table key. In the LOOP - ENDLOOP loop, the work area line is used and is displayed for every loop pass. The first field of the primary table key col1 is used for group level processing. The sum of all numeric fields is calculated each time the content of col1 changes and once for the last table line.
The executable example Grouping in Group Levels shows how the same function can be achieved using the addition GROUP BY.