Write a query to get 2nd maximum salary in an employee table ?
Answer Posted / karthik ramasamy
Select max(salary) from salarymaster where salary <(select
max(salary) from salarymaster)
OR
SELECT MAX(SALARY) FROM SALARYMASTER WHERE SALARY NOT IN
(SELECT MAX(SALARY) FROM SALARYMASTER)
OR
Select max(salary) from salarymaster where salary<(Select
max(salary) from salarymaster)
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How do you optimize a query?
How do I trace sql profiler?
what is innodb? : Sql dba
What is sql*plus?
What are the different sql languages?
What is the difference between between and in condition operators?
Can we create a trigger on view?
Is sql a oracle?
How do I start pl sql?
What is foreign key in sql with example?
what is the use of anchoring object? what r the difference between anchoring object & enclosing object? can any one tell me all the details?
The select into statement is most often used to create backup copies of tables or for archiving records?
What are two statement types in sql?
What is the use of count (*) in sql?
Can we join tables without foreign key?