ASA SQL Reference
SQL Functions
Alphabetical list of functions
Computes the average, for a set of rows, of a numeric-expression or of a set unique values.
AVG ( numeric-expression | DISTINCT column-name )
numeric-expression The expression whose average is calculated over a set of rows.
DISTINCT column-name Computes the average of the unique values in column-name. This is of limited usefulness, but is included for completeness.
This average does not include rows where the numeric expression is the NULL value. Returns the NULL value for a group containing no rows.
SQL/92 SQL/92 compatible.
SQL/99 Core feature.
Sybase Compatible with Adaptive Server Enterprise.
The following statement returns the value 49988.6.
SELECT AVG( salary ) FROM employee