Answer: You can use the below query to find out the second highest salary from employee salary table.
SELECT * FROM TblEmployeeSalary a WHERE (2=(SELECT COUNT(DISTINCT(b.salary)) FROM TblEmployeeSalary b WHERE b.salary>=a.salary))
Found interesting? Add this to: