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

Answers were Sorted based on User's Feedback



How to find the second largest salary in the emp database and also How to find 3rd,4th and so on ....

Answer / sridhar

select gross_pay from tbl_payroll where gross_pay != (select
max(gross_pay) from tbl_payroll) limit 0,3

Is This Answer Correct ?    0 Yes 8 No

How to find the second largest salary in the emp database and also How to find 3rd,4th and so on ....

Answer / rajeev

select salary-1 from users where salary in (select
max(salary) from users);

Is This Answer Correct ?    0 Yes 8 No

How to find the second largest salary in the emp database and also How to find 3rd,4th and so on ....

Answer / ashish kumar

To find nth maximum salry

Select salary from tbl_name a where
n-1=(Select count(distinct(count(*))) from tbl_name b
where b.salary>a.salary)

Is This Answer Correct ?    10 Yes 20 No

How to find the second largest salary in the emp database and also How to find 3rd,4th and so on ....

Answer / suhail

select top 1 salary from (select top 5 salary from
emp_table order by salary desc)temptable order by salary asc

Is This Answer Correct ?    17 Yes 36 No

How to find the second largest salary in the emp database and also How to find 3rd,4th and so on ....

Answer / gunjan sapra

select top 10 from tbl_name order by salary desc

Is This Answer Correct ?    4 Yes 39 No

Post New Answer

More SQL Server Interview Questions

How do I connect to sql server database?

0 Answers  


Explain the phases a transaction has to undergo?

0 Answers  


How to configure odbc dsn with different port numbers?

0 Answers  


What is exporting and importing utility?

0 Answers  


What is an active database?

0 Answers   HCL,


What is difference between equi join and natural join?

0 Answers  


Is it possible to update the views? If yes, how, if not, why?

0 Answers  


What is transact-sql ddl trigger?

0 Answers  


how many types of store procedre in sqlserver 2000?

2 Answers   ATI,


How do you trace the traffic hitting a sql server?

0 Answers  


How to find the date and time of last updated table?

3 Answers  


How to return the top 5 rows from a select query in ms sql server?

0 Answers  


Categories