aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor/nodeRecursiveunion.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/executor/nodeRecursiveunion.c')
-rw-r--r--src/backend/executor/nodeRecursiveunion.c27
1 files changed, 14 insertions, 13 deletions
diff --git a/src/backend/executor/nodeRecursiveunion.c b/src/backend/executor/nodeRecursiveunion.c
index d2488ad988e..9b74ed3208c 100644
--- a/src/backend/executor/nodeRecursiveunion.c
+++ b/src/backend/executor/nodeRecursiveunion.c
@@ -37,17 +37,18 @@ build_hash_table(RecursiveUnionState *rustate)
Assert(node->numCols > 0);
Assert(node->numGroups > 0);
- rustate->hashtable = BuildTupleHashTable(&rustate->ps,
- desc,
- node->numCols,
- node->dupColIdx,
- rustate->eqfuncoids,
- rustate->hashfunctions,
- node->numGroups,
- 0,
- rustate->tableContext,
- rustate->tempContext,
- false);
+ rustate->hashtable = BuildTupleHashTableExt(&rustate->ps,
+ desc,
+ node->numCols,
+ node->dupColIdx,
+ rustate->eqfuncoids,
+ rustate->hashfunctions,
+ node->numGroups,
+ 0,
+ rustate->ps.state->es_query_cxt,
+ rustate->tableContext,
+ rustate->tempContext,
+ false);
}
@@ -317,9 +318,9 @@ ExecReScanRecursiveUnion(RecursiveUnionState *node)
if (node->tableContext)
MemoryContextResetAndDeleteChildren(node->tableContext);
- /* And rebuild empty hashtable if needed */
+ /* Empty hashtable if needed */
if (plan->numCols > 0)
- build_hash_table(node);
+ ResetTupleHashTable(node->hashtable);
/* reset processing state */
node->recursing = false;