i need department wise top 2 employees salary.which logic
i will use

Answer Posted / vikas kapoor

select deptno,sal from
(select deptno,sal,row_number() over(partition by deptno orderby sal) r from emp ) where r<3

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many types of normalization are there?

487


What is synonyms?

570


What is pl sql package?

591


How many aggregate functions are available there in sql?

526


What are the basic sql commands?

548






Explain the difference between cursor declared in procedures and cursors declared in the package specification?

575


What is oracle sql developer?

603


What is db journal file?

518


How do you concatenate in sql?

548


What is varchar example?

572


How do I restart sql?

524


what is heap table? : Sql dba

605


What are pl/sql cursor exceptions?

570


What are different methods to trace the pl/sql code?

536


Can a table contain multiple primary key’s?

624