from the table display the 2nd highest salary?
and also the least 2nd salay?
Answer Posted / smitha
2nd Highest Salary
Select top 1 salary from (select distinct top 2 salary
from employee order by salary desc)a
order by salary
2nd Least Salary
Select top 1 salary from (select distinct top 2 salary
from employee order by salary asc)a
order by salary desc
| Is This Answer Correct ? | 3 Yes | 2 No |
Post New Answer View All Answers
What is bulkcopy in sql?
What is the default order of an order by clause?
How can you stop stored procedures from recompiling?
You want to use a perspective in an mdx query. How do you select the perspective?
how many bits ip address consist of? : Sql server database administration
Do you know what are the steps to process a single select statement?
Explain the disadvantages/limitation of the cursor?
What is mean by dml?
What are the Advantages of using CTE in sql server?
What is factless fact table? : sql server analysis services, ssas
What is an indice?
Explain the different types of backups available in sql server? : sql server database administration
How to remove duplicate rows from table?
What is the command dbcc checkdb used for?
What is difference between clustered and non clustered index?