SQL: GROUP BY ClauseThe GROUP BY clause can be used in a SELECT statement to collect data across multiple records and group the results by one or more columns.The syntax for the GROUP BY clause is:SELECT column1, column2, ... column_n, aggregate_function (expression)FROM tablesWHERE predicatesGROUP BY column1, column2, ... column_n;aggregate_function can be a function such as SUM, COUNT, MIN, or MAX.Example using the SUM functionFor...
Read more »