how to find nth highest salary
Answer Posted / amit kumar
--- Getting 4th highest salary
--- 4 can be replaced with any number
with EmpSal as
(Select *, row_number() over (order by EmpSal Desc)
as 'rownumber' from employee)
Select * from EmpSal where rownumber =4
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Is it possible to update the views? If yes, how, if not, why?
Can we update data in a view?
How to create a login account in ms sql server to access the database engine using "create login" statements?
Explain tables in SQL Azure?
Do you know the isolation level that sql server support?
How to compare the top two records using sql?
How to find Duplicate Records In table?
How do you rebuild an identity column?
How to encrypt Strored Procedure in SQL SERVER?
What is sqlcmd?
What is a virtual table in sql?
How to transfer data from a cursor to variables with a "fetch" statement?
What is use of attributehierarchyenabled? : sql server analysis services, ssas
How to scale out a federation by Sql statement?
What is snapshot replication?