how to get second highest salary in SQL(as/4000

Answer Posted / deepak

select max(sal) from emp where sal!=(select max(sal) from emp);

Is This Answer Correct ?    12 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the purpose of primary key?

529


What is the least restrictive isolation level? : Transact sql

565


What is the mutating table and constraining table?

556


What is difference between sql and mysql?

529


Explain the difference between triggers and constraints?

519






what is a record in a database ? : Sql dba

566


What is materialized view. What are different methods of refresh?

777


What does pl sql stand for?

654


Is it possible to link two groups inside a cross products after the cross products group has been created?

593


How do you explain an index number?

531


Cite the differences between execution of triggers and stored procedures?

617


How to avoid duplicate records in a query?

575


How is use pl and sql?

552


how many values can the set function of mysql take? : Sql dba

530


What are the commands used in sql?

523