Skip to content

2853. Highest Salaries Difference 👍

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
SELECT ABS(
    (
      SELECT MAX(salary) AS salary
      FROM Salaries
      WHERE department = 'Engineering'
    ) - (
      SELECT MAX(salary) AS salary
      FROM Salaries
      WHERE department = 'Marketing'
    )
  ) AS salary_difference;