Write a query to find second highest salary of an employee.

Answer Posted / mubin ahmad

select salary from employee e1 where 2=(select count(*)
from employee e2 where e2.salary>=e1.salary)

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are local and global Indexes and where they are useful.

925


What is a record in pl/sql?

547


Which is better join or inner query?

514


Can we create a trigger on view?

485


Is oracle sql free?

536






What are the three forms of normalization?

522


what happens if you no create privilege in a database? : Sql dba

529


What is file based approach?

487


Can we declare a column having number data type and its scale is larger than pricesionex: column_name number(10,100),column_name numbaer(10,-84)

535


Can we use update in sql function?

576


what is cursor. write example of it. What are the attributes of cursor.

743


Mention what is the function that is used to transfer a pl/sql table log to a database table?

484


What are sql objects?

538


What are instead of triggers?

620


What do we need to check in database testing?

554