3.5 Selectivity Factors, Table Size, and Query Cost Estimation 43
2. Push selections down the query execution plan as far as possible to be executed
earlier (rules 4, 5, 7).
3. Group a sequence of selections as much as possible (rule 3).
4. Push projections down the plan as far as possible (rules 4, 6, 7).
5. Group projections on the same tables, removing redundancies.
Figure 3.1 illustrates a query execution plan that emphasizes executing the joins
first using a bottom-up execution sequence. Figure 3.2 is the same plan, transformed to
a plan that executes the joins last using this heuristic.
3.5
Selectivity F
actors, Table Size, and Query Cost Estimation
Once we are given a candidate query execution plan to analyze, we need to be able to
estimate the ...