Write a query to get 2nd maximum salary in an employee table ?
Answer Posted / anil_abbireddy
select * from emp a where 2=(select count(distinct sal)
from emp b where a.sal<=b.sal)
| Is This Answer Correct ? | 30 Yes | 8 No |
Post New Answer View All Answers
Can you do multiple joins in sql?
in oracle 10g sw after compiling procedure how to pass parameter values ,if we (v_empid out number)how to give empid after successful compilation program.This site exact suitable for 10g with respect to question & answer same format , im trying sql browser & sql command prompt using exec procedure name & respective parameters.
What is the max nvarchar size?
How many sql databases can you have on one server?
what is the difference between $message and $$message? : Sql dba
what is not null constraint? : Sql dba
What is the file extension for sql database?
Does user triggers have entry for trigger with compilation errors?
how to use case expression? : Sql dba
Where do we use pl sql?
Can you load data into multiple tables at once? : aql loader
how to delete an existing column in a table? : Sql dba
What is rownum in sql?
How much ram can sql express use?
What is the difference between a primary key and a clustered index?