mirror of
https://github.com/postgres/postgres.git
synced 2025-06-23 14:01:44 +03:00
Remove surplus call to table_finish_bulk_insert
4de60244e
added the call to table_finish_bulk_insert to the
CopyMultiInsertBufferCleanup function. We use a CopyMultiInsertBuffer even
for non-partitioned tables, so having the cleanup do that meant we would
call table_finsh_bulk_insert twice when performing COPY FROM with
a non-partitioned table.
Here we can just remove the direct call in CopyFrom and let
CopyMultiInsertBufferCleanup handle the call instead.
This commit is contained in:
@ -3369,8 +3369,6 @@ CopyFrom(CopyState cstate)
|
|||||||
|
|
||||||
if (insertMethod != CIM_SINGLE)
|
if (insertMethod != CIM_SINGLE)
|
||||||
{
|
{
|
||||||
table_finish_bulk_insert(cstate->rel, ti_options);
|
|
||||||
|
|
||||||
/* Tear down the multi-insert buffer data */
|
/* Tear down the multi-insert buffer data */
|
||||||
CopyMultiInsertInfoCleanup(&multiInsertInfo);
|
CopyMultiInsertInfoCleanup(&multiInsertInfo);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user