aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/selfuncs.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/utils/adt/selfuncs.c')
-rw-r--r--src/backend/utils/adt/selfuncs.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/backend/utils/adt/selfuncs.c b/src/backend/utils/adt/selfuncs.c
index 0c8c05f6c2e..60549d76b7a 100644
--- a/src/backend/utils/adt/selfuncs.c
+++ b/src/backend/utils/adt/selfuncs.c
@@ -3443,13 +3443,13 @@ estimate_num_groups(PlannerInfo *root, List *groupExprs, double input_rows,
* expression, treat it as a single variable even if it's really more
* complicated.
*
- * XXX This has the consequence that if there's a statistics on the
- * expression, we don't split it into individual Vars. This affects
- * our selection of statistics in estimate_multivariate_ndistinct,
- * because it's probably better to use more accurate estimate for each
- * expression and treat them as independent, than to combine estimates
- * for the extracted variables when we don't know how that relates to
- * the expressions.
+ * XXX This has the consequence that if there's a statistics object on
+ * the expression, we don't split it into individual Vars. This
+ * affects our selection of statistics in
+ * estimate_multivariate_ndistinct, because it's probably better to
+ * use more accurate estimate for each expression and treat them as
+ * independent, than to combine estimates for the extracted variables
+ * when we don't know how that relates to the expressions.
*/
examine_variable(root, groupexpr, 0, &vardata);
if (HeapTupleIsValid(vardata.statsTuple) || vardata.isunique)
@@ -3918,7 +3918,7 @@ estimate_multivariate_ndistinct(PlannerInfo *root, RelOptInfo *rel,
if (!rel->statlist)
return false;
- /* look for the ndistinct statistics matching the most vars */
+ /* look for the ndistinct statistics object matching the most vars */
nmatches_vars = 0; /* we require at least two matches */
nmatches_exprs = 0;
foreach(lc, rel->statlist)
@@ -3964,7 +3964,7 @@ estimate_multivariate_ndistinct(PlannerInfo *root, RelOptInfo *rel,
continue;
}
- /* expression - see if it's in the statistics */
+ /* expression - see if it's in the statistics object */
foreach(lc3, info->exprs)
{
Node *expr = (Node *) lfirst(lc3);
@@ -4053,7 +4053,7 @@ estimate_multivariate_ndistinct(PlannerInfo *root, RelOptInfo *rel,
if (!AttrNumberIsForUserDefinedAttr(attnum))
continue;
- /* Is the variable covered by the statistics? */
+ /* Is the variable covered by the statistics object? */
if (!bms_is_member(attnum, matched_info->keys))
continue;
@@ -4075,7 +4075,7 @@ estimate_multivariate_ndistinct(PlannerInfo *root, RelOptInfo *rel,
if (found)
continue;
- /* expression - see if it's in the statistics */
+ /* expression - see if it's in the statistics object */
idx = 0;
foreach(lc3, matched_info->exprs)
{
@@ -5252,7 +5252,7 @@ examine_variable(PlannerInfo *root, Node *node, int varRelid,
{
HeapTuple t = statext_expressions_load(info->statOid, pos);
- /* Get index's table for permission check */
+ /* Get statistics object's table for permission check */
RangeTblEntry *rte;
Oid userid;
@@ -5276,8 +5276,8 @@ examine_variable(PlannerInfo *root, Node *node, int varRelid,
/*
* For simplicity, we insist on the whole table being
* selectable, rather than trying to identify which
- * column(s) the statistics depends on. Also require all
- * rows to be selectable --- there must be no
+ * column(s) the statistics object depends on. Also
+ * require all rows to be selectable --- there must be no
* securityQuals from security barrier views or RLS
* policies.
*/