← SQL Playground
Second-Highest Salary
MediumPremiumReturn the second-highest distinct salary as a single column named
second_highest. If there is no such salary, return NULL.Schema
departments (id, name)
employees (id, name, department_id, salary, hire_date)
Loading editor…
Hints