Grokking SQL for Tech Interviews
Ask Author
Back to course home

0% completed

Vote For New Content
Aggregate Functions
On this page

MySQL provides several aggregate functions that allow you to perform calculations on sets of data within a table. These functions are often used in conjunction with the GROUP BY clause to operate on groups of rows.

Here's a breakdown of some commonly used aggregate functions:

1. COUNT()

The COUNT() function is used to count the number of rows in a set, satisfying a given condition.

Syntax:

SELECT COUNT(student_id) FROM students;

This query gives the total count of student in the student table.

2. SUM()

The `SUM()

.....

.....

.....

Like the course? Get enrolled and start learning!

On this page