how to find second and third highest salary in SQL?
I tried this syntax :
SELECT FIRST_NAME, SALARY
FROM EMPLOYEES E1 WHERE 2-1 = (SELECT COUNT(DISTINCT SALARY)
                               FROM EMPLOYEES E2
                               WHERE E1.SALARY > E2.SALARY);
but i need to get second and third ..n highest salary ?
 
     
     
     
    