diff --git a/176-second-highest-salary/176-second-highest-salary.sql b/176-second-highest-salary/176-second-highest-salary.sql new file mode 100644 index 0000000..9839720 --- /dev/null +++ b/176-second-highest-salary/176-second-highest-salary.sql @@ -0,0 +1,8 @@ +# Write your MySQL query statement below +SELECT + IFNULL( + (SELECT DISTINCT salary + FROM Employee + ORDER BY salary DESC + LIMIT 1 OFFSET 1), + NULL) as SecondHighestSalary \ No newline at end of file