pgsql: Fix incorrect index behavior in COPY FROM with partitionedtable
В списке pgsql-committers по дате отправления:
| От | David Rowley |
|---|---|
| Тема | pgsql: Fix incorrect index behavior in COPY FROM with partitionedtable |
| Дата | |
| Msg-id | E1hYPWa-0006kx-T3@gemulon.postgresql.org обсуждение исходный текст |
| Список | pgsql-committers |
Fix incorrect index behavior in COPY FROM with partitioned tables 86b85044e rewrote how COPY FROM works to allow multiple tuple buffers to exist to once thus allowing multi-inserts to be used in more cases with partitioned tables. That commit neglected to update the estate's es_result_relation_info when flushing the insert buffer to the partition making it possible for the index tuples to be added into an index on the wrong partition. Fix this and also add an Assert in ExecInsertIndexTuples to help ensure that we never make this mistake again. Reported-by: Haruka Takatsuka Author: Ashutosh Sharma Discussion: https://postgr.es/m/15832-b1bf336a4ee246b5@postgresql.org Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/56b3b3838284f53c83556592e60688522155f57f Modified Files -------------- src/backend/commands/copy.c | 3 +++ src/backend/executor/execIndexing.c | 3 +++ src/test/regress/input/copy.source | 13 +++++++++++++ src/test/regress/output/copy.source | 17 +++++++++++++++++ 4 files changed, 36 insertions(+)
В списке pgsql-committers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера