Complete the code to count only non-NULL values in the column.
SELECT COUNT([1]) FROM employees;The COUNT function counts only non-NULL values when a column name is specified. Using COUNT(salary) counts all non-NULL salaries.
Complete the code to calculate the average salary ignoring NULL values.
SELECT AVG([1]) FROM employees;AVG ignores NULL values and calculates the average of non-NULL salaries.
Fix the error in the query to count all rows including those with NULL salaries.
SELECT COUNT([1]) FROM employees;COUNT(*) counts all rows, including those where salary is NULL.
Fill both blanks to select the maximum salary and minimum salary ignoring NULLs.
SELECT MAX([1]), MIN([2]) FROM employees;
MAX and MIN ignore NULL values and operate on the specified column.
Fill all three blanks to select the sum of salaries, count of non-NULL salaries, and average salary.
SELECT SUM([1]), COUNT([2]), AVG([3]) FROM employees;
SUM, COUNT(column), and AVG all operate on the salary column ignoring NULLs (except COUNT(*) counts all rows).