Previous Topic Next topic Print topic


AVG

ANSI DB2 SQL/DS XDB
X X X X

Averages the values in each group of a column. This function is for numeric fields only. Null values will be ignored. The format appears below:

AVG([DISTINCT]x)

where the parameter x is a numeric field. Note that in DB2 mode, performing an AVG on data of type integer or data of type small integer gives a result of an integer with decimal places truncated.

Previous Topic Next topic Print topic