How to retrieve 5th highest sal from emp table? - oracle

How to retrieve 5th highest sal from emp table?

SELECT DISTINCT (emp1.sal)
FROM EMP emp1
WHERE &N = (SELECT COUNT (DISTINCT (emp2.sal)) FROM EMP emp2 WHERE emp1.sal<= emp2.sal);
Will work for any value if N, including 5
What is $FLEX$ and $PROFILES$? Where are they used? - oracle
What is $FLEX$ and $PROFILES$? - $FLEX$ is used to get a value used in the previous value set. It is usually used to retrieve the Flex value contained in an AOL value...
oracle-trigger-inside-procedure.aspx
Trigger inside a stored procedure - A trigger cannot be called within a stored procedure. Triggers are executed automatically as a result of DML or DDl commands...
What is WATER MARK IN oracle? - oracle
What is WATER MARK IN oracle? - WATER MARK is a divided segment of used and free blocks. Blocks which are below high WATER MARK i.e. used blocks, have at least once...
Post your comment