how to find nth highest salary
Answer Posted / usha
SELECT EmpName, Salary
from
(
SELECT EmpName, Salary, Row_Number() OVER(ORDER BY SALARY
DESC) AS 'Salaries'
FROM #Employees
) emp
WHERE Salaries = n
n may be 2,3....
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
What are the 7 disadvantages to a manual system?
What are the new features introduced in SQL Server 2000? What changed between the previous version of SQL Server and the current version?
What are the benefits and tasks of object explorer? : sql server management studio
Tell me about builtinadministrator?
Write a program to fetch first 10 records from a file?
Do you know what is openxml in sql server?
How do I create a partition table in sql server?
What is meant by indexing?
What happens if ntwdblib.dll is missing on your machine?
What is resource governor?
What is outer join in sql server joins?
What is cached report?
How to rename an existing column with sql server management studio?
Can sub report data source be different from that of the parent report?
What is SQL Azure Federations?