From the course: Microsoft SQL Server 2022 Essential Training

Unlock this course with a free trial

Join today to access over 24,100 courses taught by industry experts.

Data table indexes

Data table indexes

- SQL Server depends on indexes in order to locate specific records at a table as quickly as possible. Without an index, SQL server needs to perform something called a table scan when trying to locate specific records. With this method, SQL Server simply starts at the top of the table and reads down until the appropriate data is found or the bottom of the table is reached. A table scan is how SQL Server approaches a table that doesn't include any indexing assistance or what's known as a 'heap'. A heap is simply a table that lacks an index and must be scanned completely to find a specific row. If an index is available, all of the records within the table are kept in a predictable sorted order. When a record is requested from the table a table seek is performed on something called the B Tree or a Balanced Tree Structure. In a B Tree structured index, the root level branches out into one or more intermediate levels and…

Contents