Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

select top 3 sal from each dept?

Answer Posted / chiru

select *
from (select row_number() over(partition by deptno order by sal desc) r,
b.*
from (select rownum num, a.* from emp a order by sal desc) b)
where r <= 3

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many aggregate functions are available there in sql?

931


What is the primary use of normalization?

944


Define tables and fields in a database

1081


What is the requirement of self-join?

1027


How do you declare a constant?

911


What is union and union all keyword in sql?

972


What is the use of & in pl sql?

988


how to get help information from the server? : Sql dba

877


How to order siblings in oracle hierarchy queries?

983


What is the advantage of index in sql?

917


Where is pl sql used?

905


What is pl sql in dbms?

902


What is rtm stands for?

1023


What is varchar data type in sql?

1016


What is trigger explain it?

966