CBO, we need gather objects statistics data to help optimizer choose the best plan. However, if the schema's statistics data be updated, all of the dependent execution plans may be affected. Before 10g, you just have 2 choices, none or all of them be affected. The inputing parameter is NO_INVALIDATE, the choices are true or false. If you set true, none of the plans will adapt the new statistics to reparse the sql, unless it's swapped out from library cache, or be flushed mannually. For those 24*7 databases, some sql may never be improved as we expected. And if you choose false, all of the related plans will be flushed out from library cache immediately, and all of them will be reparsed at next time execution, which may consume much of CPU. That will be a nightmare if it happens at the time that resource is tight.
|
最新文章