Query to get max and second max in oracle in one query ?
Answer Posted / samir kumar sahoo
SELECT sal FROM(SELECT DISTINCT(sal) FROM employees ORDER
BY sal DESC) WHERE ROWNUM<=2;
Is This Answer Correct ? | 23 Yes | 2 No |
Post New Answer View All Answers
What is an oracle recycle bin?
Explain the use of record option in exp command.
Explain the use of full option in exp command.
How many anonymous blocks can be defined?
Give syntax for SQL and ORACLE joins.
Are truncate and delete commands same? If so why?
What is merge statement used for?
What is coalesce function?
How to open a cursor variable?
what is IDE,DMV in sql server?
How to create a table interactively?
11. Display the client number and name and the client number and name of the person who referred that client.
How to import one table back from a dump file?
How to insert a record into a table?
What is a synonym? What are its various types?