write the query for find the top 2 highest salary in sql
server
Answer Posted / ranjeet kumar shrivastava
select * from tbl_htl_cntry e where 2>=(select
count(distinct salary) from tbl_htl_cntry where
e.salary<=salary)
it is aslo working syntax.
ranjeetvasu@rediffmail.com
Is This Answer Correct ? | 10 Yes | 3 No |
Post New Answer View All Answers
What are the differences between char and varchar in ms sql server?
Can the “if update (colname)” statement be used in a delete trigger?
Does windows server 2016 come with sql server?
What are the different types of indexes?
How to query multiple tables jointly?
Differentiate between delete and truncate.
How to get the definition of a view out of the sql server?
What are the different normalization forms?
Define cross join in sql server joins?
What happens if time-only values are provided as date and time literals?
Can a unique index be created on a column, which contains null?
What is the maximum size of a row in sql server?
What is spid in sql server profiler?
What is unpivot?
what are the types of indexes? : Sql server database administration