Write a query to get 2nd maximum salary in an employee table ?
Answer Posted / sandeep
select top(1) a.salary
from
(
select top(2)sal
from
employee
order by salary desc
)a
order by a.salary asc
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is a native sql query?
what are the differences between procedure-oriented languages and object-oriented languages? : Sql dba
What is memory optimized table?
What is sql keyword?
Mention what are the benefits of pl/sql packages?
What is the use of desc in sql?
How do I run a sql query?
What is rank function in sql?
How to fetch values from testtable1 that are not in testtable2 without using not keyword?
What is the sql*loader? : aql loader
how to include character strings in sql statements? : Sql dba
What is the difference between pl and sql?
Is big data nosql?
What is a composite primary key?
What does pragma mean?