How to find third or nth maximum salary from salary table(EmpID, EmpName, EmpSalary) in optimized way?
table(EmpID, EmpName, EmpSalary)
Third or nth maximum salary from salary table without using subquery
select salary from salary ORDER BY salary DESC OFFSET N-1 ROWS FETCH NEXT 1 ROWS ONLY
For 3rd highest salary put 2 in place of N-1