How to find 1st, 2nd, 3rd highest using select select
statement not using rownum
Answer Posted / madhavi
SELECT sal
FROM (SELECT sal, RANK() OVER(ORDER BY sal DESC) AS rnk
FROM emp)
WHERE rnk IN (1,2,3);
| Is This Answer Correct ? | 14 Yes | 3 No |
Post New Answer View All Answers
Can u please explain me the Discussion on Except ,using cast like type cast. Question in the context of difference between two tables
What are the advantages of oracle 12c?
What are data pump export and import modes?
1) Does oracle have any table which contain all the exceptions and it's code internally?
How to delete a column in an existing table in oracle?
What is meant by joins? List out the types of joins.
What are triggers in oracle?
What happens if the imported table already exists?
What is archive log in Oracle?
WHEN CURSOR MOVES FROM ONE FORM TO ANOTHER FORM, HOW MANY TRIGGER WILL BE FIRED AND WHAT ARE THEIR SEQUENCE?
If a parameter is used in a query without being previously defined, what diff. exist betw. report 2.0 and 2.5 when the query is applied ?
What is a schema in oracle?
Explain a data segment?
How to define an anonymous procedure with variables?
How do you tell what your machine name is and what is its IP address?