SELECT AVG(column_name)
FROM table_name
WHERE condition;
SELECT FIRST_NAME FROM EMPLOYEES
WHERE SALARY = (SELECT AVG(SALARY) FROM EMPLOYEES);
SELECT AVG(age) AS average_age
FROM Customers;
SELECT avg(count)
FROM
(
SELECT COUNT (*) AS Count
FROM Table T
WHERE T.Update_time =
(SELECT MAX (B.Update_time )
FROM Table B
WHERE (B.Id = T.Id))
GROUP BY T.Grouping
) as counts
SELECT student_name, avg(notes) FROM student_notes GROUP BY student_name;