1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
| -- @Title: 第二高的薪水 (Second Highest Salary)
-- @Author: 15816537946@163.com
-- @Date: 2021-03-03 15:36:49
-- @Runtime: 188 ms
-- @Memory: 0 B
# Write your MySQL query statement below
select (
select DISTINCT Salary
from Employee
order by Salary desc
limit 1,1
) SecondHighestSalary;
/*
SELECT
( SELECT DISTINCT Salary
FROM Employee
ORDER BY Salary DESC
LIMIT 1, 1 ) SecondHighestSalary;
*/
|