How to retrieve a second highest salary from a table?
Note:Suppose salaries are in duplicate values
eg:
Name Sal
Malli 60000
Pandi 60000
Rudra 45000
Ravi 45000
Answer Posted / prativa mishra
select *
from
(select salary,dense_rank() over (order by salary) kk from table_name)
where kk=2
| Is This Answer Correct ? | 7 Yes | 2 No |
Post New Answer View All Answers
What is pragma in pl sql?
State few characteristics of pl/sql?
What are the different ddl commands in sql?
How would you convert date into julian date format?
Is sql a backend language?
What is error ora-01000: maximum open cursors exceeded
define join and explain different type of joins? : Sql dba
What are records give examples?
Is sql harder than python?
What is the difference among union, minus and intersect?
What is trigger with example?
How many types of cursors supported in pl/sql?
What is delimiter sql?
How do I turn a list into a table?
What does the hierarchical profiler does?