From 0c1af2c35c7b456bd2fc76bbc9df5aa9c7911bde Mon Sep 17 00:00:00 2001 From: Alexander Korotkov Date: Thu, 6 Jun 2024 13:43:24 +0300 Subject: Rename PathKeyInfo to GroupByOrdering 0452b461bc made optimizer explore alternative orderings of group-by pathkeys. The PathKeyInfo data structure was used to store the particular ordering of group-by pathkeys and corresponding clauses. It turns out that PathKeyInfo is not the best name for that purpose. This commit renames this data structure to GroupByOrdering, and revises its comment. Discussion: https://postgr.es/m/db0fc3a4-966c-4cec-a136-94024d39212d%40postgrespro.ru Reported-by: Tom Lane Author: Andrei Lepikhov Reviewed-by: Alexander Korotkov, Pavel Borisov --- src/backend/optimizer/plan/planner.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/backend/optimizer/plan/planner.c') diff --git a/src/backend/optimizer/plan/planner.c b/src/backend/optimizer/plan/planner.c index ea107c70cb8..084c6796d03 100644 --- a/src/backend/optimizer/plan/planner.c +++ b/src/backend/optimizer/plan/planner.c @@ -6917,7 +6917,7 @@ add_paths_to_grouping_rel(PlannerInfo *root, RelOptInfo *input_rel, foreach(lc2, pathkey_orderings) { - PathKeyInfo *info = (PathKeyInfo *) lfirst(lc2); + GroupByOrdering *info = (GroupByOrdering *) lfirst(lc2); /* restore the path (we replace it in the loop) */ path = path_save; @@ -6998,7 +6998,7 @@ add_paths_to_grouping_rel(PlannerInfo *root, RelOptInfo *input_rel, /* process all potentially interesting grouping reorderings */ foreach(lc2, pathkey_orderings) { - PathKeyInfo *info = (PathKeyInfo *) lfirst(lc2); + GroupByOrdering *info = (GroupByOrdering *) lfirst(lc2); /* restore the path (we replace it in the loop) */ path = path_save; @@ -7249,7 +7249,7 @@ create_partial_grouping_paths(PlannerInfo *root, /* process all potentially interesting grouping reorderings */ foreach(lc2, pathkey_orderings) { - PathKeyInfo *info = (PathKeyInfo *) lfirst(lc2); + GroupByOrdering *info = (GroupByOrdering *) lfirst(lc2); /* restore the path (we replace it in the loop) */ path = path_save; @@ -7305,7 +7305,7 @@ create_partial_grouping_paths(PlannerInfo *root, /* process all potentially interesting grouping reorderings */ foreach(lc2, pathkey_orderings) { - PathKeyInfo *info = (PathKeyInfo *) lfirst(lc2); + GroupByOrdering *info = (GroupByOrdering *) lfirst(lc2); /* restore the path (we replace it in the loop) */ -- cgit v1.2.3