• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to get top 3 earners in emp table of SCOTT's schema using SQL  RSS feed

 
Taqi Hasan
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello
can any one tell me
How to get top 3 earners in emp table of SCOTT's schema using SQL.
I would appreciate for your prompt reply.
Regards.
Taqi
 
SJ Adnams
Ranch Hand
Posts: 925
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
select a.ename from ( select ENAME , sal, rownum rowval from emp order by sal desc) a where rownum < 4;
 
Taqi Hasan
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Lee for your kind information.
Regards.
Taqi
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!