Complete the code to calculate the average salary from the employees table.
SELECT [1](salary) FROM employees;The AVG function calculates the average value of a numeric column.
Complete the code to find the average price from the products table where category is 'Books'.
SELECT AVG(price) FROM products WHERE category = [1];String values in SQL must be enclosed in single quotes.
Fix the error in the code to correctly calculate the average age from the users table.
SELECT AVG[1]age FROM users;The AVG function requires parentheses around the column name.
Fill both blanks to calculate the average score for students with grade greater than 80.
SELECT [1](score) FROM students WHERE grade [2] 80;
Use AVG to calculate average and > to filter grades greater than 80.
Fill all three blanks to calculate the average price for products with stock less than 50 and category 'Electronics'.
SELECT [1](price) FROM products WHERE stock [2] 50 AND category = [3];
Use AVG for average, < for less than, and single quotes around string 'Electronics'.