Write a query to find five highest salaries from EMP table.
(there is a column SALARY)

Answer Posted / vishnu

select level,max(sal) from emp
where level<=5
group by level
connect by prior sal>sal
order by level Asc;

Is This Answer Correct ?    5 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain what is table in a database?

577


Can we create clustered index without primary key?

521


Which is better trigger or stored procedure?

500


What is pl sql in oracle?

582


What is sqlcontext?

549






What is auto increment in sql?

584


How many commands are in sql?

523


What is the use of %rowtype?

535


Why do we use sql constraints?

659


What is pl sql quora?

647


What is mdb stand for?

554


What is clustered and nonclustered index in sql?

497


what is a database transaction? : Sql dba

583


What is the difference between in and between in sql?

574


how to dump a table to a file with 'mysqldump'? : Sql dba

551