how to retrieve the top 3 salaries of the table using rownum

Answer Posted / kavitha

select employee_id,last_name,salary
from employees
where rownum <=3
order by salary desc

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which is better cte or subquery?

714


How to disable a trigger name update_salary?

896


what are rollup and cube in t-sql? : Transact sql

819


What is cursor and why it is required?

795


How to revise and re-run the last sql command?

837






What is partition in sql query?

723


Define sql delete statement.

744


Why do we use triggers?

719


ERROR:Insert or update on table"accnt" violates foreign key constraints "acct_to_curr_symbol" DETAILS:KEY(accnt_curr_id)(-2)is not present in the table "curr_symbol" ......solve The Problem..

2178


What does select * from mean in sql?

2544


What is the use of %rowtype?

747


What is the difference between delete, truncate and drop command?

751


What is data type in database?

730


How do you exit in sql?

815


what is the difference between cluster and non cluster index? : Sql dba

732