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 to find the second largest salary in the emp database and
also How to find 3rd,4th and so on ........ in the emp database

plz mail the answer @ mak2786@gmail.com

Answer Posted / bobby

select p.emp_id,p.name,p.salary from
( select emp_id,name,salary,dense_rank()over( order by
salary desc)rank
from empTable )p
where rank=2

Is This Answer Correct ?    1 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is RMS migrations?

2088


What is default constraint in ms sql server?

968


Is it true that rules do not apply to data already existing in a database at the time the rule is created?

990


Can we write trigger for view?

954


What is SQL Azure?

105


What is deploy, process and build? : sql server analysis services, ssas

1036


What is the bookmark lookup and rid lookup?

944


What is a deadlock and what is a live lock?

952


How to download microsoft sql server 2005 express edition?

978


What is the boxing and unboxing concept in .net?

868


How do I edit a stored procedure in sql server?

883


Tell me what are the essential components of sql server service broker?

887


Why are you getting errors when creating a new odbc dsn?

1169


Can you name some of the dml commands in sql?

962


Explain partitioned view?

1023