select the 3rd maximum salary from sql server database if 4
(just an example In practically I may not know the exact
situation) of the highest salaries are equal.

Answer Posted / sumesh.s.g

--Sumesh.S.G--
SELECT TOP 1 salary
FROM (select top 3 Salary
from dbo.TBL_Employee
order by Salary desc) as TemTable order by Salary asc
--Happy coding--

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the different types of backups avaialabe in sql server 2005?

620


What is the difference between sdf and mdf?

674


How do you set a trace flag in sql server?

549


What is a view in sql?

577


What does it mean to manipulate data?

558






What is change data capture (cdc) in sql server 2008?

561


How to skip remaining statements in a loop block using continue statements?

539


Explain how you can deploy an SSRS report?

106


What is a trigger and its types?

524


What do you mean by a Composite primary key?

588


Explain tablesample?

547


How do I get to sql server configuration manager?

511


Tell me what is normalization? Explain different forms of normalization?

543


Is sql server a database?

529


explain what are the steps you will take, if you are tasked with securing an sql server? : Sql server database administration

642