A final tool that you can use to get
aggregate data about a table is the AVG operator. The AVG operator
follows the expected syntax of:
SELECT AVG(column_name)
FROM table_name
WHERE optional_where_clause;
For example, to determine the average
salary of employees from the EMPLOYEES
table, you would use:
SELECT AVG(EMP_SALARY)
FROM EMPLOYEES;
That SQL code would yield:
AVG (SALARY)
-------------------------------
90000
-------------------------------