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

What is the difference between IN and Exists in Oracle?

Answer Posted / pankaj

In sql server,

WHEN YOU USE 'IN', WHILE CHECKING FOR WHERE CONDITION SQL SERVER ENGINE DOES WHOLE TABLE SCAN. IF YOU USE 'EXISTS' AS SOON AS ENGINE FINDS THE REQUIRED ROW IT WILL STOP EXECUTING QUERY AND GOING FURTHER SCANNING TABLE.

In Oracle,
EXISTS is very faster than IN (when the subquery results is very large)

IN is faster than EXISTS (when the subquery results is very small)

In Example -
select ename from emp
where mgr in (select empno from emp where ename = 'KING');

Exists Example -
Select ename from emp a where exists ( select 0/null from emp b where a.mgr=b.empno and ename='KING')

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many number of sessions can one group in batches?

1157


list out all the transformations which use cache?

1180


Is stop and abort are same in informatica?

999


Explain about Informatica server process that how it works relates to mapping variables?

1076


What does refresh system mean, and what are its distinctive choice?

1171


What do you mean by worklet?

1064


What is a sorter transformation?

1102


Explain scd type 3 through mapping.

999


Performance tuning in UNIX for informatica mappings?

2566


How can one identify whether mapping is correct or not without connecting session?

1445


Do you find any difficulty while working with flat files as source and target?

1098


How to differentiate between the active and passive transformations?

1161


How to extract sap data using informatica? What is abap? What are idocs?

1180


explain about unit testing? in real time?

2198


what is song in infrmatica...?

2235