how to find the second highest salary from emp table?
Answer Posted / praveen kumar.dandu
select a.sal,rank from(select sal,rank() over (order by sal
desc))a where rank=&n
<Here after printing the ranks we can retrieve we can
retreive what ever the rank we want>
| Is This Answer Correct ? | 2 Yes | 4 No |
Post New Answer View All Answers
What is auto increment feature in sql?
Why partition by is used in sql?
How do you break a loop in pl sql?
How can get second highest salary in sql?
how do you login to mysql using unix shell? : Sql dba
how to rename an existing table in mysql? : Sql dba
How do I add a database to sql?
Can we commit inside a trigger?
Why do we use subquery?
How you can copy a file to file content and file to pl/sql table in advance pl/sql?
How do I create a sql database?
What is the difference between sql and t sql?
Show the two pl/sql cursor exceptions.
What is index example?
Why select is used in sql?