diff options
author | Robert Haas | 2017-07-18 01:29:45 +0000 |
---|---|---|
committer | Robert Haas | 2017-07-18 01:29:45 +0000 |
commit | f81a91db4d1c2032632aa5df9fc14be24f5fe5ec (patch) | |
tree | 01ec760e37fcdc12db679add15f95e24f0d055dc /src/backend/executor/nodeModifyTable.c | |
parent | 533463307bf67e1bb7acc345ba7ea535c6aebb78 (diff) |
Use a real RT index when setting up partition tuple routing.
Before, we always used a dummy value of 1, but that's not right when
the partitioned table being modified is inside of a WITH clause
rather than part of the main query.
Amit Langote, reported and reviewd by Etsuro Fujita, with a comment
change by me.
Discussion: http://postgr.es/m/[email protected]
Diffstat (limited to 'src/backend/executor/nodeModifyTable.c')
-rw-r--r-- | src/backend/executor/nodeModifyTable.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/backend/executor/nodeModifyTable.c b/src/backend/executor/nodeModifyTable.c index 8d17425abe..77ba15dd90 100644 --- a/src/backend/executor/nodeModifyTable.c +++ b/src/backend/executor/nodeModifyTable.c @@ -1914,6 +1914,7 @@ ExecInitModifyTable(ModifyTable *node, EState *estate, int eflags) num_partitions; ExecSetupPartitionTupleRouting(rel, + node->nominalRelation, &partition_dispatch_info, &partitions, &partition_tupconv_maps, |