Skip to content

ABAP Keyword Documentation →  ABAP - Short Reference 

aggregate - Short Reference

Reference

Other versions: 7.31 | 7.40 | 7.54

Syntax


... { MAX( [DISTINCT] col ) 
    | MIN( [DISTINCT] col )
    | AVG( [DISTINCT] col )
    | SUM( [DISTINCT] col )
    | COUNT( DISTINCT col )
    | COUNT( * )
    | COUNT(*) } ... .

Effect

Aggregate expressions in the SELECT statement.

Additions

  • MAX( [DISTINCT] col )
    Maximum total of the values in the column col.
  • MIN( [DISTINCT] col )
    Minimum total of the values in the column col.
  • AVG( [DISTINCT] col )
    Average total of the values in the column col.
  • SUM( [DISTINCT] col )
    Total of the values in the column col.
  • COUNT( DISTINCT col )
    Number of different values in the column col.
  • COUNT( * ), COUNT(*)
    Number of lines in the result quantity.