MySQL Aggregate Functions
- COUNT(): returns the number of rows that matches a specified criterion.
- AVG(): returns the average value of a numeric column.
- SUM(): returns the total sum of a numeric column.
COUNT() Syntax:
SELECT COUNT(column_name) FROM table_name WHERE condition;
Try It Yourself
Edit the code below and click Run to see the result live.