how to retrieve the top 3 salaries of the table using rownum
Answer Posted / nitesh
select sal from emp e where 3>=(select count(distinct sal)
from emp where sal>e.sal) order by sal desc;
| Is This Answer Correct ? | 5 Yes | 3 No |
Post New Answer View All Answers
What is #table in sql?
what are the type of locks ? : Sql dba
define sql delete statement ? : Sql dba
What is the difference between subquery and correlated query?
Why does sql need a server?
How can I delete duplicate rows?
What are the rules to be applied to nulls whilst doing comparisons?
What is sqlexception in java?
What is cursor explain with example?
Can we create table in function?
Why do we need cursor in pl sql?
Why is a primary key important?
Why do we create views in sql?
Explain character-manipulation functions?
What is a sql schema used for?