Write a query to get 2nd maximum salary in an employee table ?
Answer Posted / uday
Hi friends i think it is surely work because i worked for this.
select * from emp e where 1=(select count(distinct d.esal)
from emp d where d.esal>e.esal)
any one plz try if it's not work
plz let me know.
uday_testing@yahoo.co.in
| Is This Answer Correct ? | 7 Yes | 3 No |
Post New Answer View All Answers
Can we use commit inside a trigger?
what are the features and advantages of object-oriented programming? : Sql dba
What are the events on which a database trigger can be based?
Why functions are used in sql?
How do I know if I have sql express or standard?
What is the purpose of a sql?
What is pl sql code?
How to change a value of the field ‘salary’ as 7500 for an employee_name ‘john’ in a table employee_details?
What is varchar data type in sql?
What is the maximum number of rows in sql table?
How many row comparison operators are used while working with a subquery?
What are the types of join and explain each?
Where the sql database files are stored?
What is the use of partition by in sql?
Explain ddl statements in pl/sql?