GROUP BY

The GROUP BY clause summarizes data.

#GROUP BY CLAUSE

SELECT NAME, COL#, COUNT(*) AS Number_of_times
FROM
col$
WHERE
COL# = 1
GROUP BY NAME, COL#;

Every object that is not in the aggreagate function such as COUNT() must be in the GROUP BY.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top