MySQL SQL

MySQL AVG()

Calculate the arithmetic average.

SELECT AVG(price) AS average_price
FROM products;

MySQL ignores NULL values when calculating AVG(). Use ROUND() to format the result.