• R/O
  • HTTP
  • SSH
  • HTTPS

pg_hint_plan: Commit

firtst release


Commit MetaInfo

Revisionc94c75fc64170d3bd6444fdcab007ca17ddcd442 (tree)
Time2018-11-13 16:00:34
AuthorKyotaro Horiguchi <horiguchi.kyotaro@lab....>
CommiterKyotaro Horiguchi

Log Message

Update core.c and make_jion_rel.c following core

Apply changes ever made on core.

Change Summary

Incremental Difference

--- a/core.c
+++ b/core.c
@@ -39,7 +39,7 @@
3939 * restriction_is_constant_false()
4040 *
4141 *
42- * Portions Copyright (c) 1996-2017, PostgreSQL Global Development Group
42+ * Portions Copyright (c) 1996-2018, PostgreSQL Global Development Group
4343 * Portions Copyright (c) 1994, Regents of the University of California
4444 *
4545 *-------------------------------------------------------------------------
@@ -1076,6 +1076,9 @@ try_partitionwise_join(PlannerInfo *root, RelOptInfo *rel1, RelOptInfo *rel2,
10761076 if (!IS_PARTITIONED_REL(joinrel))
10771077 return;
10781078
1079+ /* The join relation should have consider_partitionwise_join set. */
1080+ Assert(joinrel->consider_partitionwise_join);
1081+
10791082 /*
10801083 * Since this join relation is partitioned, all the base relations
10811084 * participating in this join must be partitioned and so are all the
@@ -1084,6 +1087,10 @@ try_partitionwise_join(PlannerInfo *root, RelOptInfo *rel1, RelOptInfo *rel2,
10841087 Assert(IS_PARTITIONED_REL(rel1) && IS_PARTITIONED_REL(rel2));
10851088 Assert(REL_HAS_ALL_PART_PROPS(rel1) && REL_HAS_ALL_PART_PROPS(rel2));
10861089
1090+ /* The joining relations should have consider_partitionwise_join set. */
1091+ Assert(rel1->consider_partitionwise_join &&
1092+ rel2->consider_partitionwise_join);
1093+
10871094 /*
10881095 * The partition scheme of the join relation should match that of the
10891096 * joining relations.
@@ -1163,4 +1170,3 @@ try_partitionwise_join(PlannerInfo *root, RelOptInfo *rel1, RelOptInfo *rel2,
11631170 child_restrictlist);
11641171 }
11651172 }
1166-
--- a/make_join_rel.c
+++ b/make_join_rel.c
@@ -7,17 +7,13 @@
77 * src/backend/optimizer/path/joinrels.c
88 * make_join_rel()
99 *
10- * Portions Copyright (c) 2013-2017, NIPPON TELEGRAPH AND TELEPHONE CORPORATION
11- * Portions Copyright (c) 1996-2017, PostgreSQL Global Development Group
10+ * Portions Copyright (c) 2013-2018, NIPPON TELEGRAPH AND TELEPHONE CORPORATION
11+ * Portions Copyright (c) 1996-2018, PostgreSQL Global Development Group
1212 * Portions Copyright (c) 1994, Regents of the University of California
1313 *
1414 *-------------------------------------------------------------------------
1515 */
1616
17-static void populate_joinrel_with_paths(PlannerInfo *root, RelOptInfo *rel1,
18- RelOptInfo *rel2, RelOptInfo *joinrel,
19- SpecialJoinInfo *sjinfo, List *restrictlist);
20-
2117 /*
2218 * adjust_rows: tweak estimated row numbers according to the hint.
2319 */
Show on old repository browser