Re: A problem in ExecModifyTable

2021-08-17 Thread Tom Lane
David Rowley writes: > I'd been looking at the code in ExecInitModifyTable() that's the same > as what you pasted thinking you meant that. I think for the check for > partitioned tables in ExecModifyTable() then it's likely just dead > code. It seems to be causing a bit of confusion though, so m

Re: A problem in ExecModifyTable

2021-08-17 Thread David Rowley
On Tue, 17 Aug 2021 at 19:06, 李杰(慎追) wrote: > Your answer explains that we still need to ModifyTable node without Leaf > partitions. > You are right about this. > > But you can review the source code again, I'd been looking at the code in ExecInitModifyTable() that's the same as wha

回复:A problem in ExecModifyTable

2021-08-17 Thread 李杰(慎追)
Hi, David Your answer explains that we still need to ModifyTable node without Leaf partitions. You are right about this. But you can review the source code again, ``` /* * Fetch rows from subplan, and execute the required table modification * for each row.

Re: A problem in ExecModifyTable

2021-08-16 Thread David Rowley
On Tue, 17 Aug 2021 at 15:56, 李杰(慎追) wrote: > According to my understanding, the parent table of a partitioned table does > not store any tuples. > Then why is "relkind = = RELKIND_PARTITIONED_TABLE" suddenly added here ? We'll need some sort of ResultRelInfo in the case that all partitions are

A problem in ExecModifyTable

2021-08-16 Thread 李杰(慎追)
Hi hackers, Recently, I noticed a great patch in pg 14. "Rework planning and execution of UPDATE and DELETE. (86dc90056dfdbd9d1b891718d2e5614e3e432f35)" This changes the DML execution of the partitioned table and makes it more friendly. But I am very confused about the following changes: ``` +