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...


How to Remove the 3rd highest salary person record from
table?

Answers were Sorted based on User's Feedback



How to Remove the 3rd highest salary person record from table?..

Answer / suresh babu

delete from employees where employee_id in (select
employee_id from employees where 3 =(select count(distinct
e.salary) from employees e
where e.salary >= employees.salary));

Is This Answer Correct ?    17 Yes 1 No

How to Remove the 3rd highest salary person record from table?..

Answer / khan

DELETE FROM
(SELECT EMP_ID, SALARY, DENSE_RANK() OVER (ORDER BY SALARY DESC) AS CNT FROM EMPLOYEE)
WHERE CNT = 3;

Is This Answer Correct ?    9 Yes 5 No

How to Remove the 3rd highest salary person record from table?..

Answer / prasanna

DELETE FROM
(SELECT EMP_ID, SALARY, DENSE_RANK() OVER (ORDER BY SALARY
DESC) AS CNT FROM EMPLOYEE)
WHERE CNT = 3;

or

delete from employees where employee_id in (select
employee_id from employees where 2 =(select count(distinct
e.salary) from employees e
where e.salary > employees.salary));

Is This Answer Correct ?    3 Yes 3 No

How to Remove the 3rd highest salary person record from table?..

Answer / avnish srivastava-test engg fc

select max(salary)from employees
where
salary < (select max(salary)from employees where
salary < (select max(salary) from employees))

Is This Answer Correct ?    10 Yes 11 No

How to Remove the 3rd highest salary person record from table?..

Answer / jainish

select max(salary)from employees
where
salary < (select max(salary)from employees where
salary < (select max(salary) from employees))

Is This Answer Correct ?    4 Yes 5 No

How to Remove the 3rd highest salary person record from table?..

Answer / krishna

delete from emp where sal >(select max(sal) from emp where
sal >(select max(sal) from emp where sal >(select max(sal)
from emp)));

Is This Answer Correct ?    0 Yes 2 No

How to Remove the 3rd highest salary person record from table?..

Answer / manoj

delete from employee where sal = (select sal from (select sal from employee order by sal desc) where rownum = 3);

Is This Answer Correct ?    1 Yes 3 No

How to Remove the 3rd highest salary person record from table?..

Answer / nathan

DELETE FROM emp
WHERE empno = (SELECT empno
FROM (SELECT empno, ROWNUM rn
FROM (SELECT empno
FROM emp
ORDER BY sal DESC))
WHERE rn = 3);

Is This Answer Correct ?    1 Yes 3 No

How to Remove the 3rd highest salary person record from table?..

Answer / basanti

delete from employee where salary(select salary from(select
distinct (salary) from employee where salary is NOT NULL
order by salary desc) where rownum=n);

Is This Answer Correct ?    0 Yes 3 No

Post New Answer

More Oracle General Interview Questions

What are the different types of partitions in oracle?

0 Answers  


What is the effect of setting the value "CHOOSE" for OPTIMIZER_GOAL, parameter of the ALTER SESSION Command ?

2 Answers  


how to get second highest sal of emp table

6 Answers  


what is normalisation?what are its uses?

0 Answers  


without using count(*) and rownum how can we count total record in a table

5 Answers   AC, HP,


What is a procedure in oracle?

0 Answers  


How to see the table columns used in an index?

0 Answers  


How to do a full database export?

0 Answers  


what is integrity constrains?

3 Answers  


What are the execution control statements in oracle?

0 Answers  


What is a Temporary Segment ?

2 Answers  


How to divide query output into groups in oracle?

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)