Find out the 3rd highest salary?
Answer Posted / priyanga.g
1) Select MAX(salary) from Programmer where salary not
in(select top 2 salary from Programmer order by salary desc)
2) Select max(salary) from programmer where salary<
(select MAX(salary) from Programmer where salary<(select
MAX(salary) from Programmer))
3) Select MAX(salary) from Programmer e where 2=(select
COUNT(*) from programmer b where b.salary>e.salary )
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
Does user triggers have entry for trigger with compilation errors?
Why do we use sql constraints?
what is a table called, if it has neither cluster nor non-cluster index? What is it used for? : Sql dba
What are the different datatypes available in PL/SQL?
what are the different tables present in mysql, which type of table is generated when we are creating a table in the following syntax: create table employee (eno int(2),ename varchar(10)) ? : Sql dba
Explain ddl statements in pl/sql?
What is union?
Why having clause is used in sql?
How do you know if a relationship is 2nf?
What are types of joins?
What is the trigger in sql?
What are inner outer left and right joins in sql?
what is primary key? : Sql dba
How does postgresql compare to "nosql"?
define join and explain different type of joins? : Sql dba