diff options
author | Alexander Korotkov <akorotkov@postgresql.org> | 2024-04-30 11:54:42 +0300 |
---|---|---|
committer | Alexander Korotkov <akorotkov@postgresql.org> | 2024-04-30 11:54:42 +0300 |
commit | 885742b9f88b9386368ee94df8c94d154677ffba (patch) | |
tree | 47964bf784106ccb969b5ce1c084d58c495cbd24 /doc/src | |
parent | 5bcbe9813bf91bcf14ef3a580162f1600dd3d1d4 (diff) | |
download | postgresql-885742b9f88b9386368ee94df8c94d154677ffba.tar.gz postgresql-885742b9f88b9386368ee94df8c94d154677ffba.zip |
Change the way ATExecMergePartitions() handles the name collision
The name collision happens when the name of the new partition is the same as
the name of one of the merging partitions. Currently, ATExecMergePartitions()
first gives the new partition a temporary name and then renames it when old
partitions are deleted. That negatively influences the naming of related
objects like indexes and constrains, which could inherit a temporary name.
This commit changes the implementation in the following way. A merging
partition gets renamed first, then the new partition is created with the
right name immediately. This resolves the issue of the naming of related
objects.
Reported-by: Alexander Lakhin
Discussion: https://postgr.es/m/edfbd846-dcc1-42d1-ac26-715691b687d3%40postgrespro.ru
Author: Dmitry Koval, Alexander Korotkov
Reviewed-by: Robert Haas, Justin Pryzby, Pavel Borisov
Diffstat (limited to 'doc/src')
0 files changed, 0 insertions, 0 deletions