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 / sarat

TO FIND THE Nth HIGHEST SAL IN EMP TABLE

SELECT MIN (salary) as NthSalary FROM emptable WHERE
salary IN ( SELECT DISCINCT TOP N salary FROM emptable
ORDER BY salary DESC )

Is This Answer Correct ?    3 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is sql server replication? : sql server replication

925


how you can deploy an ssrs report?

172


What are trace flags?

963


What are Row versions of DataRow?

978


What happens if null values are involved in bitwise operations?

967


What type of Index will get created after executing the above statement?

1047


What are scheduled tasks in sql server?

1011


Explain nested stored procedure. Syntax and an example for create nested stored procedure?

884


Can you explain what is the use of custom fields in report?

1002


What is the main difference between ‘between’ and ‘in’ condition operators?

1106


How to delete an existing database user?

970


What are triggers? How many triggers you can have on a table? How to invoke a trigger on demand?

1130


What do you mean by authentication modes in sql server?

1030


Explain hostprotectionattribute in sql server 2005?

961


What is the purpose of sql profiler in sql server?

962