how will I find the first 5 highest salaried employees in
each dept in oracle.
Answer Posted / jas
select a.sal,a.emp_no from employee a
where 5=(select distinct(count(*) from
employee b where a.sal> b.sal)
| Is This Answer Correct ? | 8 Yes | 9 No |
Post New Answer View All Answers
How to create a table index?
How to delete all rows a table in oracle?
How to get maxsal , minsal, ename department wise in single query
What types of joins are used in writing subqueries?
What is rich query?
Explain oracle instance.
How are extents allocated to a segment?
What is oracle data type?
How do we create privileges in oracle?
What is a sub query and what are the different types of subqueries?
Give the different types of rollback segments.
Tab A A B ------ 1 A 2 B 3 C Tab B A B ----- 4 D 5 E 6 F Generate the value into B table from A table. Only table A has the value. Write the SQL query to get B table value.
How to join two tables in a single query using oracle?
Difference between pre-select and pre-query
How to load a large xml file?