PostgreSQL AGGREGATE functions
What is an aggregate function?
An aggregate function produced a single result for an entire group or table.
Aggregate functions are used to produce summarized results. They operate on sets of rows. They return results based on groups of rows. By default, all rows in a table are treated as one group. The GROUP BY clause of the select statement is used to divide rows into smaller groups.
List of aggregate functions
|This function returns the number or rows or non NULL values for a column
|This function returns the sum of a selected column.
|This function returns the largest value of a specific column.
|This function returns the smallest value of a specific column.
|This function returns the average value for a specific column.
|Name of the aggregate function.
|Expression is a value or value of the column which itself does not contain any aggregate expression.
|The order_by_clause is optional which arranged the result in an order.
- Weekly Trends
- 100 Python Projects for Beginners with solution
- Mastering NumPy: 100 Exercises with solutions
- SQL Tutorial
- SQL Inner Join
- Python Exercises, Practice, Solution
- Python Interview Questions and Answers: Comprehensive Guide
- MongoDB Exercises, Practice, Solution
- SQL Exercises, Practice, Solution - JOINS
- Java Basic Programming Exercises
- SQL Subqueries
- C# Sharp Basic Exercises
- SQL COUNT() with distinct
- Java Collection Exercises