Skip to menu

Korea Oracle User Group

Guru's Articles

원문 : https://sqlmaria.com/2020/11/03/explain-the-explain-plan-cardinality-estimates/

 

 

Explain the Explain Plan: Cardinality Estimates

In last week’s post, I began a series on how to read and interpret Oracle execution plans by explaining what an execution plan is and how to generate one. This week I’m going to tackle the most important piece of information the Optimizer shares with you via the execution plan, it’s cardinality estimates.

What is a Cardinality Estimate?

A cardinality estimate is the estimated number of rows, the optimizer believes will be returned by a specific operation in the execution plan. The Optimizer determines the cardinality for each operation based on a complex set of formulas that use table and column level statistics as input (or the statistics derived by dynamic sampling). It’s considered the most important aspect of an execution plan because it strongly influences all of the other decisions the optimizer makes.

In part 4 of our series, I share some of the formulas used by the optimizer to estimate cardinalities, as well as showing you how to identify cardinalities in a plan. I also demonstrate multiple ways to determine if the cardinality estimates are accurate.

What can cause a Cardinality Misestimate and how do I fix it?

Several factors can lead to incorrect cardinality estimates even when the basic table and column statistics are up to date. In part 5 of our series, I explain the leading causes of cardinality misestimates and how you can address them.

Next weeks, instalment will be all about the different access methods available to the Optimizer and what you can do to encourage the optimizer to select the access method you want!

Don’t forget this series also covers, how to read an explain plan as well as the different join methods and join orders.

Don’t forget more information on the Oracle Optimizer can always be found on the Optimizer blog.

No. Subject Author Date Views
Notice Guru's Article 게시판 용도 ecrossoug 2015.11.18 607
43 Troubleshooting Another Complex Performance Issue – Oracle direct path inserts and SEG$ contention file ecrossoug 2015.11.16 100
42 Brief about Workload Management in Oracle RAC file ecrossoug 2015.11.18 514
41 NOUG Session: How Cache Fusion Works file ecrossoug 2015.11.18 137
40 How many checkpoints in Oracle database ? [1] file 명품관 2015.11.20 283
39 Parallel Execution 12c New Features Overview file 명품관 2015.11.23 111
38 On Invokers and Outs file 명품관 2015.11.23 102
37 Top 5 SQL Monitor Features file 명품관 2015.12.01 780
36 Oracle Enterprise Manager Cloud Control 13c Release 1 (13.1.0.0) Installation on Oracle Linux 6 and 7 명품관 2015.12.23 203
35 Oracle 12c SQL – Using JSON 명품관 2015.12.29 2583
34 Upgrade a Pluggable Database in Oracle 12c 명품관 2015.12.30 174
33 (유투브) KISS series on Analytics: Dealing with null - Connor McDonald 명품관 2016.01.05 155
32 How do I capture a 10053 trace for a SQL statement called in a PL/SQL package? 명품관 2016.01.06 264
31 Why You Can Get ORA-00942 Errors with Flashback Query 명품관 2016.02.01 453
30 What is an In-Memory Compression Unit (IMCU)? 명품관 2016.02.24 181
29 Hybrid Columnar Compression Common Questions 명품관 2016.03.04 191
28 Parameter Recommendations for Oracle Database 12c - Part I 명품관 2016.03.07 844
27 Parameter Recommendations for Oracle Database 12c - Part II 명품관 2016.03.18 354
26 Oracle Linux 6.7 with Oracle 11.2.0.4 RAC 명품관 2016.04.15 9694
25 Quick tip on Function Based Indexes 명품관 2016.04.19 191
Up