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

How to create prepared statements using odbc_prepare()?

1070


Tell me what is difference between clustered and non clustered index?

946


Explain how to send email from sql database?

1053


How many cores do I need for sql server 2016?

905


How to use subqueries with the in operators in ms sql server?

1080


Difference between drill down and drill through report.

964


What are the different authentication modes in sql server?

1126


What are the different types of sql server replication? : sql server replication

1278


What is the federation in sql azure?

97


Mention a few common trace flags used with sql server?

940


Can a cursor be updated? If yes, how you can protect which columns are updated?

1114


What is log shipping? Can we do logshipping with SQL Server 7.0 ?

998


What is the process of indexing?

1010


What is collation?

1146


What is use of except clause? How does it differ from not in clause?

1022