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


Please Help Members By Posting Answers For Below Questions

Why indexing is needed?

516


Is sql harder than python?

602


What is trigger and types?

562


What is a ddl command?

532


how can we find the number of rows in a table using mysql? : Sql dba

582






What can you do with pl sql?

557


What is group function in sql?

531


Does a user_objects view have an entry for a trigger?

570


What is the use of sqlerrd 3?

519


What does plv msg allows you to do?

673


What is meant by user defined function?

581


how to analyze tables with 'mysqlcheck'? : Sql dba

542


Can pl sql procedure have a return statement?

548


What is the difference between rollback and rollback to statements?

581


What is the life of an sql statement?

523