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...

how will I find the first 5 highest salaried employees in
each dept in oracle.

Answer Posted / karthik

select * from (select ename,eno,dept,sal,row_number() over
(partition by dept order by sal desc)top5 from emp) where
top5 <= 5

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to experiment a data lock in oracle?

1062


What are the major difference between truncate and delete?

1067


How to use regular expression in pattern match conditions in oracle?

1046


21. Using a set operator, display the client number of all clients who have ever placed an order and whose whose name does not contain the string Sm.

2119


How to write a left outer join with the where clause in oracle?

1090


How to use "in out" parameter properly?

1056


How do I spool in oracle?

1017


How to declare a local variable?

1132


How to export data to a csv file?

1313


Explain what are the characteristics of data files?

1088


What is an Oracle index?

1663


What is a named program unit?

1093


Explain about integrity constraint?

1133


src name sex a,male b,female c,male d,female Required output : male female a,b c,d tried pivot but was not successfull select * from src pivot (max(name) for sex in ('MALE','FEMALE'));

1695


What are the advantages of oracle?

1032