Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


You have one employee table having 3 entries emp_id, Mgr_id
and salary. Mgr_id is also referencing emp_id. so now find
out the emp_id which are having the second highest salary,
under a particular manager.

Answers were Sorted based on User's Feedback



You have one employee table having 3 entries emp_id, Mgr_id and salary. Mgr_id is also referencing ..

Answer / kumar mrityunjay singh

SELECT *
FROM (SELECT EMPLOYEE_ID,MANAGER_ID,SALARY,DENSE_RANK() OVER(ORDER BY SALARY DESC)RN FROM EMPLOYEES WHERE MANAGER_ID='&ENTER_MANAGER_ID')WHERE RN < '&VALUE_UPTO'
/

Is This Answer Correct ?    8 Yes 4 No

You have one employee table having 3 entries emp_id, Mgr_id and salary. Mgr_id is also referencing ..

Answer / rajesh

select * from (select
emp_id,mgr_id,salary,dense_rank()over(partition by mgr_id order by salary desc nulls last) rn from emp) where rn=2;

Is This Answer Correct ?    5 Yes 1 No

You have one employee table having 3 entries emp_id, Mgr_id and salary. Mgr_id is also referencing ..

Answer / chandra reddy

select empno,ename,deptno,sal from(select e.*,b.sal,rank()over(order by sal desc)send_h from em e join em1 b on e.empno=b.empno) where send_h=2

Is This Answer Correct ?    1 Yes 1 No

Post New Answer

More Oracle General Interview Questions

what is foreign key?

5 Answers  


Explain about your project and its relation to the current job position you are applying to?

0 Answers  


How do I connect to oracle database?

0 Answers  


can anyody please send me the dump for Oracle 10g certifications for DBA path?

0 Answers  


How to write a query with a full outer join in oracle?

1 Answers  


How different is ms access and oracle?

0 Answers  


What is recovery manager(rman) backup in Oracle?

0 Answers   MCN Solutions,


What is a Garbage Collection? and what is full recursive Garbage collection?

0 Answers   RBS,


What privilege is needed for a user to insert rows to tables in another schema?

0 Answers  


What are the components of Physical database structure of Oracle Database?

4 Answers  


how to use sequence and what use of sequence cache

1 Answers  


Explain cascading triggers.

0 Answers  


Categories
  • Oracle General Interview Questions Oracle General (1809)
  • Oracle DBA (Database Administration) Interview Questions Oracle DBA (Database Administration) (261)
  • Oracle Call Interface (OCI) Interview Questions Oracle Call Interface (OCI) (10)
  • Oracle Architecture Interview Questions Oracle Architecture (90)
  • Oracle Security Interview Questions Oracle Security (38)
  • Oracle Forms Reports Interview Questions Oracle Forms Reports (510)
  • Oracle Data Integrator (ODI) Interview Questions Oracle Data Integrator (ODI) (120)
  • Oracle ETL Interview Questions Oracle ETL (15)
  • Oracle RAC Interview Questions Oracle RAC (93)
  • Oracle D2K Interview Questions Oracle D2K (72)
  • Oracle AllOther Interview Questions Oracle AllOther (241)