SQL - Subqueries
How can you modify this query to show each employee's salary and the highest salary in their department?
Assuming
SELECT employee_id, salary, (SELECT MAX(salary) FROM employees) AS max_dept_salary FROM employees;Assuming
employees has department_id column.