Loading, please wait...

Aggregate Functions

Aggregate functions are used to compute against a "returned column of numeric data" from your SELECT statement. They basically summarize the results of a particular column of selected data.

 

Here are the Aggregate Functions

MIN

It returns the smallest value in a given column

MIN(column | expression)

 

MAX

It returns the largest value in a given column

MAX(column | expression)

 

SUM

It returns the sum of the numeric values in a given column

SUM(ALL | DISTINCT column)

 

AVG

It returns the average value of a given column

AVG( ALL | DISTINCT)

 

COUNT

It returns the total number of values in a given column

COUNT ( [ALL | DISTINCT] column | expression | *)

 

COUNT(*)

It returns the number of rows in a table

COUNT ( [ALL | DISTINCT] column | expression | *)