Aggregate Functions in SQL

In this lesson, we will learn about the different aggregate functions available in SQL.

We'll cover the following...

Aggregate functions in SQL

In database management, an aggregate function is a function where the values of multiple rows are grouped together to form a single value of more significant meaning.

We will discuss the following in this lesson:

  • COUNT()
  • SUM()
  • AVG()
  • MIN()
  • MAX()

Again we will be using the CUSTOMERS table.

The COUNT function

The COUNT() function returns the number of rows that match a specified criterion.

Syntax

The syntax for the COUNT() function is as follows:

SELECT
...