Distinct Counting with SQL COUNT()

The SQL DISTINCT keyword forces SELECT operations to be performed on unique rows (ignoring duplicate values). If you are counting rows (using the COUNT() aggregate function) then DISTINCT may only be used if a column name is specified. DISTINT may not be used with COUNT(*). (Applies to: ColdFusion All)

Leave a Reply