Indexes in SQL Server
When and why should we use Indexes?? What are indexes basically?
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Rajeesh MenothPosted Jul 25, 2015, 3:23 AM
Santhakumar MunuswamyPosted Jul 24, 2015, 3:56 PM
Manoj BhoirPosted Jul 24, 2015, 11:53 AM
An index can be used to efficiently find all row matching some column in your query and then walk through only that subset of the table to find exact matches. If you don't have indexes on any column in the WHERE clause, the SQL server have to walk through the whole table and check every row to see if it matches, which may be a slow operation on big tables.
The index can also be a UNIQUE index, which means that you cannot have duplicate values in that column, or a PRIMARY KEY which in some storage engines defines where in the database file the value is stored.
Manas MohapatraPosted Jul 24, 2015, 10:19 AM