Aggregate. Returns the number of distinct rows in a group.
count ( distinct expression )
distinct expression  | 
A column of any datatype, except binary.  | 
This function counts all sets of non-NULL rows and returns an integer. Duplicates are not counted. A distinct expression is a column or another distinct expression that is counted.