SUM

SQL SUM Function

The SUM function returns the sum of all values from the select. Null values are ignored.

SQL SUM syntax

SELECT SUM(column_name)
FROM table_name;

Training_Course

IDNAMEDURATIONPRICE
1SQL5200
2T-SQL7700
3MySQL5600
4PL/SQL7800
5PostgreSQL6500

Example

select SUM(PRICE) from Training_Course;

Results

2800