Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How does Statitics Feedback really works in 12c?

950599Sep 27 2014 — edited Sep 28 2014

Hello,

I am studying the 12c material and have a question about Statistics Feedback (or Cardinality Feedback).

Reading about the Statistics Feedback i understand that the actual number of rows are written to a Plan Directive

- During the first execution of a SQL statement, the optimizer generates an execution plan.

- After the first execution, the optimizer disables monitoring for statistics feedback.

- If the query executes again, then the optimizer uses the corrected cardinality estimates instead of its usual estimates.

Source: http://docs.oracle.com/database/121/TGSQL/tgsql_optcncpt.htm#TGSQL94983

But what happens if the data becomes skewed in the next hours and the plan should better not be used?

When or how will the plan become invalid and will the optimizer hard parse a new plan?

Is anybody able to explain this to me?

Thank you in advance.

Regards,

Harry

This post has been answered by Franck Pachot on Sep 28 2014
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 26 2014
Added on Sep 27 2014
4 comments
354 views