What is the difference between IN and EXISTS operators in
SQL Server?
Answer Posted / monal
HERE'S THE SIMPLE ANSWER:
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.
SO BASICALLY EXISTS IS FASTER AS COMPARED TO IN.
Is This Answer Correct ? | 146 Yes | 14 No |
Post New Answer View All Answers
What is the stuff?
How to filter out duplications in the returning rows in ms sql server?
how would you improve etl (extract, transform, load) throughput?
Explain system rowset functions?
What is the difference between writing data to mirrored drives versus raid5 drives
How to use go command in "sqlcmd"?
What is ddl and dml commands?
what exactly sql injuction.how to overcome.....
Define right outer join in sql server joins?
Explain ranking functions?
what are user defined datatypes and when you should go for them? : Sql server database administration
what kind of lan types do you know? : Sql server database administration
What is the order by used for?
What is a mixed extent?
what is the Ticketing tool used in Wipro technologies at Bangalore...???