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

Answer Posted / muneer ahamed

select rownum as rank,sal from (select rownum,sal from emp
order by sal desc)
where rownum<4

Is This Answer Correct ?    4 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how to dump a table to a file with 'mysqldump'? : Sql dba

739


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 are the non-standard sql commands supported by 'mysql'? : Sql dba

777


What is the maximum number of triggers, you can apply on a single table?

735


what is index? : Sql dba

747






How do you modify a table in sql?

802


Which language is used in sql?

730


Is mariadb nosql?

771


Where not exists in sql?

675


Does group by remove duplicates?

754


What is the purpose of the sql select top clause?

738


What is left join in postgresql?

750


What do you understand by case manipulation functions?

733


Can procedure in package be overloaded?

838


what is a view? : Sql dba

814