|
EMP |
ID |
Name |
Country |
Salary |
1 |
Vijay |
India |
6000 |
2 |
Bill |
USA |
8000 |
3 |
Kris |
France |
3000 |
|
SELECT
SUM (Salary) as 'SUM',
AVG (Salary) as 'AVG',
MIN (Salary) as 'MIN',
MAX (Salary) as 'MAX',
COUNT(*) as 'COUNT(*)',
COUNT_BIG(Salary) as 'COUNT_BIG',
COUNT(DISTINCT Country) as 'COUNT'
FROM EMP
|
Output |
SUM |
AVG |
MIN |
MAX |
COUNT(*) |
COUNT_BIG |
COUNT |
17000 |
5666 |
3000 |
8000 |
3 |
3 |
3 |
|