how to find the n'th highest salary from emp ?

Answer Posted / jaya u

SELECT A.EMPNAME ,A.SAL FROM EMP A
WHERE A.SAL = (SELECT DISTINCT (b.sal)
FROM EMP B WHERE ROWNUM = &N
ORDER BY B.SAL DESC );

Is This Answer Correct ?    0 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to convert numbers to characters in oracle?

590


What is a Garbage Collection? and what is full recursive Garbage collection?

2393


What is the best way to do multi-row insert in oracle?

567


Is the After report trigger fired if the report execution fails ?

2406


What are the set operators union, union all, minus & intersect meant to do?

568






How to commit the current transaction in oracle?

578


How to create a new user account in oracle?

584


Explain a private synonyms?

639


How to sort output in descending order in oracle?

580


How to use regular expression in pattern match conditions in oracle?

579


How to compare dates in oracle sql?

659


Explain alias?

717


What is index in Oracle?

594


What is the sid in oracle?

538


Explain the use of file option in exp command.

603