From the course: Advanced SQL for Application Development

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Covering indexes

Covering indexes

From the course: Advanced SQL for Application Development

Start my 1-month free trial

Covering indexes

- [Narrator] Now we're going to turn our attention to something called a covering index. Now a covering index is not a new type, like a B-tree or a hash index. Instead, a covering index is one that is created based on the values that are stored in the index. Now, let's think about what happens when we use an index. Basically it starts when the query plan builder determines which indexes to use to satisfy a query. The locations of the rows are retrieved from the index, and then the rows are retrieved either from cache or persistent storage and then we apply filtering, joining, functions, etc., and then we return the results, so that's the basic structure of an execution plan. Now, a covering index is an index in which all columns referenced in a query are in that index, and what that means is there's no need to retrieve data from the table and that saves a seek operation. So what we have is a series of steps in which…

Contents