how will I find the first 5 highest salaried employees in
each dept in oracle.
Answers were Sorted based on User's Feedback
Answer / lakshya
SELECT salary FROM employee where rownum < 6 ORDER BY
salary DESC
group by dept;
| Is This Answer Correct ? | 11 Yes | 39 No |
How do I decide when to use right joins/left joins or inner joins or how to determine which table is on which side?
How to convert characters to dates in oracle?
How do we create privileges in oracle?
What is hot backup and logical backup?
What are the arithmetic operations?
src name sex a,male b,female c,male d,female Required output : male female a,b c,d tried pivot but was not successfull select * from src pivot (max(name) for sex in ('MALE','FEMALE'));
21. Using a set operator, display the client number of all clients who have ever placed an order and whose whose name does not contain the string Sm.
A USER HAVING CREATE SESSION PREVILAGE CAN ALTER PASSWORD/CHANGE PASSWORD?
If I have a select statment which retrives 2 rows, & that rows have the same data in all the fields except the last field and I want to merge the 2 rows to be in 1 row with concatenating the last field which have the different data.... eg: the 1st row has these fields: A-B-C the second row has: A-B-X ........ i want to merge the two row to be in one row like ----> A- B- C,X
What exactly do quotation marks around the table name do?
What are privileges and grants?
Can a parameter be passed to a cursor?