how to find nth highest salary
Answer Posted / neeraj kumar
select top(1) salary from(
select distinct nth salary
from emp
order by salary desc)a
order by salary
In this answer you can put any position in place of nth then you find the salary.
If you are satisfied this answer then reply me please.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Explain the categories of stored procedure?
What is use of except clause?
What is constraints and its types?
what is an index? : Sql server database administration
How to connect a database with sql express.?
In which files does sql server actually store data?
What do you mean by subquery?
How do you send email on SQL Server?
List all the types of user-defined functions?
What is the difference between for trigger and after trigger?
How to Sync Two SQL Azure Databases?
What do you understand by a view? What does the with check option clause for a view do?
Can you roll back the ddl statement in a trigger?
What you can do to delete a table without the delete trigger firing?
Explain for xml explicit mode?