how to find the second highest salary from emp table?
Answer Posted / arun
select distinct (a.salary) from employees a
where &N = (select count (distinct(b.salary))
from employees b where a.salary <= b.salary);
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What are sql objects?
what is a tablespace? : Sql dba
What are the features of pl sql?
Does sql between include endpoints?
Why we use cross join?
What are the sql commands?
What is the basic form of sql query?
what are the properties and different types of sub-queries? : Sql dba
how to use 'mysql' to run sql statements? : Sql dba
Is it possible to read/write files to-and-from PL/SQL?
What is the largest value that can be stored in a byte data field?
What is the difference between the conventional and direct path loads? : aql loader
what are the performance and scalability characteristics of mysql? : Sql dba
What is difference between joins and union?
How do you write an index?