Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

2nd highest salary in mysql

#Corelated Subquery
SELECT Id, Salary
FROM Employee e
WHERE 2=(SELECT COUNT(DISTINCT Salary) FROM Employee p
WHERE e.Salary<=p.Salary)
Source by www.java67.com #
 
PREVIOUS NEXT
Tagged: #highest #salary #mysql
ADD COMMENT
Topic
Name
2+9 =