how to retrieve the top 3 salaries of the table using rownum
Answer Posted / swapnareddy
select sal from emp a where 3>(select
count(distinct(sal))from emp b where a.sal<b.sal);
| Is This Answer Correct ? | 4 Yes | 3 No |
Post New Answer View All Answers
what are rollup and cube in t-sql? : Transact sql
how to calculate the difference between two dates? : Sql dba
What is auto increment?
which types of join is used in sql widely? : Sql dba
What is rank function in sql?
How would you reference column values before and after you have inserted and deleted triggers?
How do I partition a table in sql?
What is a natural join sql?
Explain the difference between triggers and constraints?
How much does sqlite cost?
How do I count records in sql?
Why join is faster than subquery?
Are pl sql variables case sensitive?
What are the two virtual tables available at the time of database trigger execution?
What is the use of double ampersand (&&) in sql queries? Give an example