Informatica QA teams may need salary extracts grouped by organizational department for validation and reporting. The result should preserve departments even when no employee has a valid salary record.
Write a PostgreSQL query that returns the maximum salary for every department in the Informatica employee directory, along with each employee who earns that maximum salary.
| Column | Type | Description |
|---|---|---|
| department_idPK | INT | Unique department identifier |
| department_name | VARCHAR(100) | Department name |
| Column | Type | Description |
|---|---|---|
| employee_idPK | INT | Unique employee identifier |
| employee_name | VARCHAR(100) | Employee full name |
| department_id | INT | Department assigned to the employee |
| salary | DECIMAL(12,2) | Annual employee salary |