Search notes:

SQL Server: aggregate functions

NULL value is eliminated by an aggregate or other SET operation.
Beware of integers in avg()

See also

The approx_count_distinct function (feature approximate count distinct of Intelligent Query Processing)

Index