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

Query to get max and second max in oracle in one query ?

Answer Posted / shareef

select ename,empno,sal,r from(select ename,empno,sal,dense_rank() over(order by sal desc) r from emp) where r=3; ----by using dense_rank()

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the roles of dba?

1063


Explain the use of record length option in exp command.

1060


please explain.. DB architecture ...

2011


what is meant by magic query

2175


Oracle

2371


What is save point in oracle database?

1289


Is oracle the best database?

961


What does sharding mean?

991


What is oracle latest version?

1092


What is a parameter file in oracle?

1122


How to insert multiple rows with one insert statement in oracle?

1075


How many memory layers are in the oracle shared pool?

1174


How to start your 10g xe server?

1032


What do you mean by merge in oracle?

991


What's dateware house and what's clustor with practicle example

2166