/*29. Write a query in SQL to display the average salary of employees for each department who gets a commission percentage.*/
SELECT department_id, AVG(salary)   
    FROM employees   
        WHERE commission_pct IS NOT NULL   
            GROUP BY department_id; 