Write a query to get 2nd maximum salary in an employee table ?
Answer Posted / gaurav mishra
The answer query is......
Select max(sal) from emp a where (&N-1) in(select count
(distinct(b.sal)) from emp b where a.sal<b.sal);
Is This Answer Correct ? | 5 Yes | 4 No |
Post New Answer View All Answers
Can a select statement fire a trigger?
How can I change database name in sql?
what are enums used for in mysql? : Sql dba
Explain mutating table error.
What is scalar and vector?
how can we repair a mysql table? : Sql dba
What are the different types of functions in sql?
What is orm in sql?
Does view contain data?
Can we delete column in sql?
Mention what are different methods to trace the pl/sql code?
What is materialized view. What are different methods of refresh?
How is sql used in oracle?
What are different types of functions in sql?
Is left join same as join?