Write a query to get 2nd maximum salary in an employee table ?
Answer Posted / sushma
SELECT * from
(SELECT * FROM emp ORDER BY sal DESC)
WHERE rownum <= 2
MINUS
SELECT * from
(SELECT * FROM emp ORDER BY sal DESC)
WHERE rownum < 2
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Can cursors be part of a trigger body?
What is rank () in sql?
What is the most common sql injection tool?
Why do we use sql constraints? Which constraints we can use while creating database in sql?
How many columns should be in an index?
Explain the working of foreign key?
What is identity column in sql server?
what is cursor and its type, what is ref cursor write a syntax to pass ref cursor into procedure out fucntion and call the procedure
how to do backup entire database? : Transact sql
What are tables and fields?
Which is faster union or join?
Explain unique key in sql.
what is a stored procedure? : Sql dba
What company owns postgresql?
Differentiate pl/sql and sql?