O'Reilly logo

Cost-Based Oracle Fundamentals by Jonathan Lewis

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 3Single Table Selectivity

After the chapter on tablescans, you may have expected a chapter on indexed access paths. But the predicted number of rows (cardinality) generated by an operation plays a crucial part in selecting initial join orders and optimum choice of indexes, so it is useful to have a good understanding of how the optimizer estimates the number of rows that are going to be produced at each step of a plan.

The reason why this chapter's title includes the term selectivity, rather than cardinality, is that the optimizer's calculations of cardinality are based on estimating the expected fraction of the rows in the current data set that would pass a particular test. That fraction is the number we call the selectivity. After ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required