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 WHERE AND IN?
OR
1. SELECT * FROM EMPLOYEE WHERE EMPID=123
2. SELECT * FROM EMPLOYEE WHERE EMPID IN (123)
WHAT IS THE DIFFERENCE?

Answer Posted / aditya bisoi

Actually Both Query will return Same Result....
But Performance wise 1st Query better..Bcz it will return the Exact Record with out check hole record in the table....

But when we use IN operator then the sql engine will do the Table scan and retrive the Result...

Is This Answer Correct ?    5 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain an incremental backup?

940


What is a mixed extent?

955


How data can be copied from one table to another table?

902


List the types of recovery model available in sql server?

873


Why the trigger fires multiple times in single login?

1155


When I delete any data from a table, does the sql server reduce the size of that table?

959


What are the fixed server level roles? : sql server security

1054


How do I find query history in sql server?

879


What is normalization according to you and explain its different levels?

900


What is self contained multi valued query?

951


What do you understand by replication in sql server?

997


Can a trigger be created on a view?

897


What is the main purpose of having conversation group?

848


How to verify the port number of the sql server?

1042


What is the use of sign function?

1036