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

find out the second highest salary?

Answer Posted / raghu

second highest salary department wise query would be this

select e.dept_id,e.salary,e.emp_name,e.rank from (select
dept_id,emp_name,salary,dense_rank() over (partition by
dept_id order by salary desc nulls last) rank
from employee)e
where e.rank = 2

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to create an oracle database manually?

1023


How is it different from a normal table?

970


How to use an explicit cursor without open statements?

1015


What is null value in oracle?

1037


what is the difference between functional dependecy and multilevel dependency?

2422


What is oracle latest version?

1041


What are the major difference between truncate and delete?

988


Does oracle charge for java?

1010


why dont we assign not null constraint as table level constraint.

2685


How to create id with auto_increment on oracle?

939


How do I learn what codesets are available in oracle?

999


What are the advantages of oracle 12c?

1124


List out the components of logical database structure of oracle database.

987


What are the differences between primary key and unique key?

950


what is normalisation?what are its uses?

2214