Skip to content

Commit bd54b37

Browse files
committed
Merge branch 'picky_nodes' into arrange_append
2 parents fc50c38 + bc3ec59 commit bd54b37

File tree

3 files changed

+16
-13
lines changed

3 files changed

+16
-13
lines changed

pg_pathman.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -161,14 +161,14 @@ _PG_init(void)
161161
runtimeappend_plan_methods.CustomName = "RuntimeAppend";
162162
runtimeappend_plan_methods.CreateCustomScanState = runtimeappend_create_scan_state;
163163

164-
runtimeppend_exec_methods.CustomName = "RuntimeAppend";
165-
runtimeppend_exec_methods.BeginCustomScan = runtimeappend_begin;
166-
runtimeppend_exec_methods.ExecCustomScan = runtimeappend_exec;
167-
runtimeppend_exec_methods.EndCustomScan = runtimeappend_end;
168-
runtimeppend_exec_methods.ReScanCustomScan = runtimeappend_rescan;
169-
runtimeppend_exec_methods.MarkPosCustomScan = NULL;
170-
runtimeppend_exec_methods.RestrPosCustomScan = NULL;
171-
runtimeppend_exec_methods.ExplainCustomScan = runtimeppend_explain;
164+
runtimeappend_exec_methods.CustomName = "RuntimeAppend";
165+
runtimeappend_exec_methods.BeginCustomScan = runtimeappend_begin;
166+
runtimeappend_exec_methods.ExecCustomScan = runtimeappend_exec;
167+
runtimeappend_exec_methods.EndCustomScan = runtimeappend_end;
168+
runtimeappend_exec_methods.ReScanCustomScan = runtimeappend_rescan;
169+
runtimeappend_exec_methods.MarkPosCustomScan = NULL;
170+
runtimeappend_exec_methods.RestrPosCustomScan = NULL;
171+
runtimeappend_exec_methods.ExplainCustomScan = runtimeappend_explain;
172172

173173
DefineCustomBoolVariable("pg_pathman.enable",
174174
"Enables pg_pathman's optimizations during the planner stage",

runtimeappend.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
* ------------------------------------------------------------------------
99
*/
1010
#include "postgres.h"
11+
#include "utils/memutils.h"
1112
#include "runtimeappend.h"
1213
#include "pathman.h"
1314

@@ -16,7 +17,7 @@ bool pg_pathman_enable_runtimeappend = true;
1617

1718
CustomPathMethods runtimeappend_path_methods;
1819
CustomScanMethods runtimeappend_plan_methods;
19-
CustomExecMethods runtimeppend_exec_methods;
20+
CustomExecMethods runtimeappend_exec_methods;
2021

2122

2223
Path *
@@ -48,7 +49,7 @@ Node *
4849
runtimeappend_create_scan_state(CustomScan *node)
4950
{
5051
return create_append_scan_state_common(node,
51-
&runtimeppend_exec_methods,
52+
&runtimeappend_exec_methods,
5253
sizeof(RuntimeAppendState));
5354
}
5455

@@ -84,6 +85,8 @@ runtimeappend_exec(CustomScanState *node)
8485
quals = ExecQual(scan_state->custom_expr_states,
8586
node->ss.ps.ps_ExprContext, false);
8687

88+
ResetExprContext(node->ss.ps.ps_ExprContext);
89+
8790
if (quals)
8891
return slot;
8992
}
@@ -109,7 +112,7 @@ runtimeappend_rescan(CustomScanState *node)
109112
}
110113

111114
void
112-
runtimeppend_explain(CustomScanState *node, List *ancestors, ExplainState *es)
115+
runtimeappend_explain(CustomScanState *node, List *ancestors, ExplainState *es)
113116
{
114117
RuntimeAppendState *scan_state = (RuntimeAppendState *) node;
115118

runtimeappend.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ extern bool pg_pathman_enable_runtimeappend;
5454

5555
extern CustomPathMethods runtimeappend_path_methods;
5656
extern CustomScanMethods runtimeappend_plan_methods;
57-
extern CustomExecMethods runtimeppend_exec_methods;
57+
extern CustomExecMethods runtimeappend_exec_methods;
5858

5959
Path * create_runtimeappend_path(PlannerInfo *root, AppendPath *inner_append,
6060
ParamPathInfo *param_info, List *runtime_clauses,
@@ -74,6 +74,6 @@ void runtimeappend_end(CustomScanState *node);
7474

7575
void runtimeappend_rescan(CustomScanState *node);
7676

77-
void runtimeppend_explain(CustomScanState *node, List *ancestors, ExplainState *es);
77+
void runtimeappend_explain(CustomScanState *node, List *ancestors, ExplainState *es);
7878

7979
#endif

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy