find out the third highest salary?
Answer Posted / selvaraj anna university coe
In Oracle 9i:
-------------
SQL> SELECT MAX(salary) FROM emp WHERE LEVEL=&no CONNECT BY
PRIOR Salary>salary;
Enter value for no: 3
old 1: SELECT MAX(SALARY) FROM EMP WHERE LEVEL=&no
CONNECT BY PRIOR SALARY>SALARY
new 1: SELECT MAX(SALARY) FROM EMP WHERE LEVEL=3 CONNECT
BY PRIOR SALARY>SALARY
MAX(SALARY)
-----------
500000
SQL>
Is This Answer Correct ? | 8 Yes | 5 No |
Post New Answer View All Answers
How is it different from a normal table?
How translate command is different from replace?
How to shutdown your 10g xe server from command line?
In which language oracle has been developed?
How to pass parameters to procedures in oracle?
What is recycle bin in Oracle?
What is dynamic proxy?
What is the difference between postgresql and oracle?
Explain about achiever in sql?
you are a universe designer and report developer in BO, what type of information you gather from client?Briefly explain plz
What is ordinary table in oracle?
How to rebuild an index in oracle?
Explain about the analyze command in oracle?
How would you best determine why your MVIEW couldnt FAST REFRESH?
Give the various rollback segment states.