Chapter 8. Execution Plan Management
As Robert Burns famously said, “The best-laid plans of mice and men often go awry.”1 No matter how thoroughly the optimizer works to find the best plan, it’s inevitable that some plans will be less than perfect. When we don’t agree with the default decision of the optimizer, we need a way to impose our own plan. Furthermore, sometimes we simply want to ensure that the plan that exists today will not be overridden in the future. Finally, we want to do our best to make sure that if the optimizer makes a change to the plan in the future, that change is for the better.
1 As comedian Eddie Izzard asks, “Does this imply that some of the less well-thought-out mice plans do quite well?”
In the previous chapter, we ...