What is “Group by” clause

Group by” clause group similar data so that aggregate values can be derived.

The “Group by” clause in a database management system (DBMS) is used to group rows that have the same values into summary rows or groups based on one or more columns. It is commonly used with aggregate functions like COUNT, SUM, AVG, MAX, or MIN to perform calculations on each group of rows. Essentially, it helps in categorizing data and applying aggregate functions to each category.