Salary by specialty
mediumFor each specialization, calculate average salary and show highest averages first.
Hospital Database · SQLite
Run your SQL answer to see the returned rows and check it.
SELECT specialization, AVG(salary) AS average_salary FROM doctors GROUP BY specialization ORDER BY average_salary DESC;