统计视图和REOPT都使优化器可以计算出更精确的基数估计,而后选择一个最佳查询执行计划。
Both statistical views and REOPT allow the optimizer to compute a more accurate cardinality estimate and consequently choose an optimal query execution plan.
如果远程视图包含一个复杂的查询,那么使用表级统计信息(例如视图昵称的基数)可能使人产生误解。
If the remote view contains a complex query, using table-level statistics such as the cardinality for the nickname over the view can be misleading.
对于本文中的查询,收集了引用表、列、索引的统计数据,如表基数、列基数等等。
For the query in this article, the basic statistics of the referenced tables, columns and indexes were collected, such as the table cardinality, column cardinality, an so on.
而且RIDSCN和fetch操作符的基数也被更正了,这样就可以说明in谓词和等式谓词间的统计关联。
And the cardinality is corrected at the RIDSCN and FETCH operators, which accounts for the statistical correlation between the in and equality predicates.
和1.31亿的就业岗位基数相比,这两个数据在统计上并不高。
Neither figure is statistically significant from zero, given that the growth is compared to a base of 131 million jobs.
每个工具的用户列表贴子数量可以表明它的用户基数(省略了贴子的实际数量,因为单独一个月的统计可能给读者造成误解)。
The number of user-list posts for each tool gives us an idea of its user base. (The actual number of posts is omitted as statistics for a single month could be misleading.)
下面使用以上讨论的相同的示例数据,阐释在使用和不使用查询的统计视图的情况下基数估计的差别。
Using the same sample data just discussed above, the following illustrates the difference in cardinality estimates with and without the use of statistical view for the query.
您可以利用DB2 9.5 中的多列统计信息的扩展用途来为优化器提供更多的信息,从而使优化器更好地估计基数,选择最佳的查询访问计划。
You can leverage the extended use of multi-column statistics in DB2 9.5 to provide the optimizer more information to better estimate the cardinality in order to choose an optimal query access plan.
这个示例解释说明了部分统计信息对于优化器估计基数的能力的影响。
This example illustrates the effect that partial statistics have on the ability of the optimizer to estimate the cardinality.
基数估计是这样一种过程:在应用了谓词或执行了聚集之后,优化器使用统计信息确定部分查询结果的大小。
Cardinality estimation is a process by which the optimizer USES statistics to determine the size of partial query results after predicates are applied or aggregation is performed.
优化器根据可用的统计信息计算基数的估计值,即预计查询返回的行数。
The optimizer calculates its cardinality estimate — that is, the estimated number of rows returned by the query — based on the statistics available.
不使用统计视图-在这种情况下,对于数据的基数的估计明显不准确。
No statistical view - Here the cardinality based on the data is off significantly.
选举官员和分析人士警告说,现在公布的统计结果基数仍然太小,不足以得出谁已获胜的结论,同时投票结果已经因被控普遍存在选民欺诈的情况而受到质疑。
Election officials and analysts caution the vote totals released are still too small to draw any conclusions about the outcome, which is already tainted by widespread voter fraud allegations.
然后优化器会使用新创建的索引和在其上收集的统计信息来更正查询访问计划的基数估计值。
With the new index created, and statistics collected on it, the optimizer corrects the cardinality estimate of the query access plan.
如果表的统计信息是最新的,那么就可以通过如下语句快速检查现有表内列的基数。
If your table statistics are up to date, you can quickly and inexpensively check the cardinality of the columns in your existing table by issuing the following statement.
在没有列组统计信息的情况下再次收集统计信息的话,优化器会选择一个类似如下所示的查询访问计划,它的基数估计值为2。
A query access plan similar to the following is chosen by the optimizer, with a cardinality estimate of 2.
在没有列组统计信息的情况下再次收集统计信息的话,优化器会选择一个类似如下所示的查询访问计划,它的基数估计值小于2。
A query access plan similar to the following is chosen by the optimizer, with a cardinality estimate under 2.
他们声称用于频率统计的人口基数必须从嫌疑犯的特定基因库中获得。
They maintain that the population base used to give frequency statistics must be drawn from the suspect's particular gene pool.
负责统计员工每年社保、公积缴纳基数调整的统计和申报;
Responsible for their yearly social security, reserve statistical adjustment of statistics and pay base declare;
负责统计员工每年社保、公积缴纳基数调整的统计和申报;
Responsible for their yearly social security, reserve statistical adjustment of statistics and pay base declare;
应用推荐