Ex 8-1
Ex 8-1
Assignment 8-1
function
• Operate on sets of rows to give one result per group any group function
function
function
function
function
elements.
1. AVG, COUNT :
FROM EMPLOYEES;
Output:
Salary calculation.
MAX, MIN:
function
"Example2"
FROM EMPLOYEES;
Output:
The maximum of 20 salaries in employees table is 24000. The
STDDEV, VARIANCE:
· For two sets of data with approximately the same mean, the
FROM EMPLOYEES;
SUM:
FROM EMPLOYEES;
Output:
FROM d_events;
9000
3. SELECT TO_CHAR(ROUND(AVG(salary),2), '$999999.99')
as "Average Salary"
FROM f_staffs
$8.38
as "Total Salary"
FROM f_staffs
$66.75
FROM employees
6.one
This way the null fields beings ignored will also be counted in.
FROM f_orders
FROM employees;
29-Jan-2000
not exist
b. SELECT SUM(cost)
TRUE
c. SELECT SUM(event_date)
g. SELECT MIN(event_date)
TRU50)