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


Delete the emps whose salaries are lowest sals of their own
dept.

Answers were Sorted based on User's Feedback



Delete the emps whose salaries are lowest sals of their own dept...

Answer / raji_4u

DELETE FROM EMP E1
WHERE E1.SAL =
(SELECT MIN(SAL) FROM EMP E2
WHERE E1.DEPTNO = E2.DEPTNO
)

Is This Answer Correct ?    15 Yes 3 No

Delete the emps whose salaries are lowest sals of their own dept...

Answer / nagendra

delete from emp where sal in (select min(sal) from emp group
by deptno)

Is This Answer Correct ?    7 Yes 7 No

Delete the emps whose salaries are lowest sals of their own dept...

Answer / venkyhulk1

delete from emp where eno in
(SELECT
eno
FROM
(select eno, rank() over ( partition by dno order by
salary) rank , salary from emp) e
WHERE
e.rank=1)


vgupalli@gmail.com

Is This Answer Correct ?    1 Yes 1 No

Delete the emps whose salaries are lowest sals of their own dept...

Answer / divya chaudhry

delete from emp where (depno,nvl2(sal,sal,0)) in ( select
depno,min(nvl2(sal,sal,0)) from emp group by depno )

Is This Answer Correct ?    0 Yes 3 No

Delete the emps whose salaries are lowest sals of their own dept...

Answer / roopesh kumar

delete from emp where (deptno,nvl(comm,0)) in (select
deptno,min(nvl(comm,0)) from emp
group by deptno)

Is This Answer Correct ?    0 Yes 4 No

Post New Answer

More SQL PLSQL Interview Questions

How to execute a stored procedure?

0 Answers  


What is anonymous block in sql?

0 Answers  


What are the conditions an underlying table must satisfy before a cursor can be used by a positioned update or delete statement? : Transact sql

0 Answers  


What is oracle and pl sql?

0 Answers  


What is the default value of CHAR type?

3 Answers   Bosch,


What is a primary key called that is made up of more than one field?

0 Answers  


difference between anonymous blocks and sub-programs.

0 Answers  


which operator is used in query for pattern matching? : Sql dba

0 Answers  


how to add a new column to an existing table in mysql? : Sql dba

0 Answers  


What are different clauses used in sql?

0 Answers  


Why commit is not used in triggers?

0 Answers  


Can a table contain multiple primary key’s?

0 Answers  


Categories