From the course: Advanced SQL for Application Development
Unlock the full course today
Join today to access over 24,000 courses taught by industry experts.
Covering indexes
From the course: Advanced SQL for Application Development
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…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
(Locked)
Overview of index types2m 26s
-
(Locked)
Using B-tree indexes and range scans2m 6s
-
Using hash indexes and equality operations1m 32s
-
(Locked)
Covering indexes2m 23s
-
(Locked)
Indexes and bulk data loading2m 18s
-
(Locked)
Avoiding index locks3m 3s
-
(Locked)
Challenge: Define a B-tree and a hash index37s
-
(Locked)
Solution: Defining B-tree and hash indexes57s
-
(Locked)
-
-
-
-
-