public inbox for [email protected]help / color / mirror / Atom feed
pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. 6+ messages / 1 participants [nested] [flat]
* pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. @ 2025-04-02 15:13 Tom Lane <[email protected]> 0 siblings, 0 replies; 6+ messages in thread From: Tom Lane @ 2025-04-02 15:13 UTC (permalink / raw) To: [email protected] Need to do CommandCounterIncrement after StoreAttrMissingVal. Without this, an additional change to the same pg_attribute row within the same command will fail. This is possible at least with ALTER TABLE ADD COLUMN on a multiple-inheritance-pathway structure. (Another potential hazard is that immediately-following operations might not see the missingval.) Introduced by 95f650674, which split the former coding that used a single pg_attribute update to change both atthasdef and atthasmissing/attmissingval into two updates, but missed that this should entail two CommandCounterIncrements as well. Like that fix, back-patch through v13. Reported-by: Alexander Lakhin <[email protected]> Author: Tender Wang <[email protected]> Reviewed-by: Tom Lane <[email protected]> Discussion: https://postgr.es/m/[email protected] Backpatch-through: 13 Branch ------ REL_15_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/2d6cfb0cddd35d724da4441c57e1c41a3991cbcb Modified Files -------------- src/backend/commands/tablecmds.c | 2 ++ src/test/regress/expected/inherit.out | 15 ++++++++++++++- src/test/regress/sql/inherit.sql | 3 ++- 3 files changed, 18 insertions(+), 2 deletions(-) ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. @ 2025-04-02 15:13 Tom Lane <[email protected]> 0 siblings, 0 replies; 6+ messages in thread From: Tom Lane @ 2025-04-02 15:13 UTC (permalink / raw) To: [email protected] Need to do CommandCounterIncrement after StoreAttrMissingVal. Without this, an additional change to the same pg_attribute row within the same command will fail. This is possible at least with ALTER TABLE ADD COLUMN on a multiple-inheritance-pathway structure. (Another potential hazard is that immediately-following operations might not see the missingval.) Introduced by 95f650674, which split the former coding that used a single pg_attribute update to change both atthasdef and atthasmissing/attmissingval into two updates, but missed that this should entail two CommandCounterIncrements as well. Like that fix, back-patch through v13. Reported-by: Alexander Lakhin <[email protected]> Author: Tender Wang <[email protected]> Reviewed-by: Tom Lane <[email protected]> Discussion: https://postgr.es/m/[email protected] Backpatch-through: 13 Branch ------ REL_14_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/d31d39cfe4f5f357c5ebf986efec61021cdf729d Modified Files -------------- src/backend/commands/tablecmds.c | 2 ++ src/test/regress/expected/inherit.out | 15 ++++++++++++++- src/test/regress/sql/inherit.sql | 3 ++- 3 files changed, 18 insertions(+), 2 deletions(-) ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. @ 2025-04-02 15:13 Tom Lane <[email protected]> 0 siblings, 0 replies; 6+ messages in thread From: Tom Lane @ 2025-04-02 15:13 UTC (permalink / raw) To: [email protected] Need to do CommandCounterIncrement after StoreAttrMissingVal. Without this, an additional change to the same pg_attribute row within the same command will fail. This is possible at least with ALTER TABLE ADD COLUMN on a multiple-inheritance-pathway structure. (Another potential hazard is that immediately-following operations might not see the missingval.) Introduced by 95f650674, which split the former coding that used a single pg_attribute update to change both atthasdef and atthasmissing/attmissingval into two updates, but missed that this should entail two CommandCounterIncrements as well. Like that fix, back-patch through v13. Reported-by: Alexander Lakhin <[email protected]> Author: Tender Wang <[email protected]> Reviewed-by: Tom Lane <[email protected]> Discussion: https://postgr.es/m/[email protected] Backpatch-through: 13 Branch ------ REL_13_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/dd34cbfce296007165e896ce19b5177a9d1b87e1 Modified Files -------------- src/backend/commands/tablecmds.c | 2 ++ src/test/regress/expected/inherit.out | 15 ++++++++++++++- src/test/regress/sql/inherit.sql | 3 ++- 3 files changed, 18 insertions(+), 2 deletions(-) ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. @ 2025-04-02 15:13 Tom Lane <[email protected]> 0 siblings, 0 replies; 6+ messages in thread From: Tom Lane @ 2025-04-02 15:13 UTC (permalink / raw) To: [email protected] Need to do CommandCounterIncrement after StoreAttrMissingVal. Without this, an additional change to the same pg_attribute row within the same command will fail. This is possible at least with ALTER TABLE ADD COLUMN on a multiple-inheritance-pathway structure. (Another potential hazard is that immediately-following operations might not see the missingval.) Introduced by 95f650674, which split the former coding that used a single pg_attribute update to change both atthasdef and atthasmissing/attmissingval into two updates, but missed that this should entail two CommandCounterIncrements as well. Like that fix, back-patch through v13. Reported-by: Alexander Lakhin <[email protected]> Author: Tender Wang <[email protected]> Reviewed-by: Tom Lane <[email protected]> Discussion: https://postgr.es/m/[email protected] Backpatch-through: 13 Branch ------ REL_16_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/053222a97b1310485851ec8d6212c96632f56ff8 Modified Files -------------- src/backend/commands/tablecmds.c | 2 ++ src/test/regress/expected/inherit.out | 15 ++++++++++++++- src/test/regress/sql/inherit.sql | 3 ++- 3 files changed, 18 insertions(+), 2 deletions(-) ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. @ 2025-04-02 15:13 Tom Lane <[email protected]> 0 siblings, 0 replies; 6+ messages in thread From: Tom Lane @ 2025-04-02 15:13 UTC (permalink / raw) To: [email protected] Need to do CommandCounterIncrement after StoreAttrMissingVal. Without this, an additional change to the same pg_attribute row within the same command will fail. This is possible at least with ALTER TABLE ADD COLUMN on a multiple-inheritance-pathway structure. (Another potential hazard is that immediately-following operations might not see the missingval.) Introduced by 95f650674, which split the former coding that used a single pg_attribute update to change both atthasdef and atthasmissing/attmissingval into two updates, but missed that this should entail two CommandCounterIncrements as well. Like that fix, back-patch through v13. Reported-by: Alexander Lakhin <[email protected]> Author: Tender Wang <[email protected]> Reviewed-by: Tom Lane <[email protected]> Discussion: https://postgr.es/m/[email protected] Backpatch-through: 13 Branch ------ REL_17_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/0941aadcd55b58a03af5d06f3374ca168522097f Modified Files -------------- src/backend/commands/tablecmds.c | 2 ++ src/test/regress/expected/inherit.out | 15 ++++++++++++++- src/test/regress/sql/inherit.sql | 3 ++- 3 files changed, 18 insertions(+), 2 deletions(-) ^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. @ 2025-04-02 15:13 Tom Lane <[email protected]> 0 siblings, 0 replies; 6+ messages in thread From: Tom Lane @ 2025-04-02 15:13 UTC (permalink / raw) To: [email protected] Need to do CommandCounterIncrement after StoreAttrMissingVal. Without this, an additional change to the same pg_attribute row within the same command will fail. This is possible at least with ALTER TABLE ADD COLUMN on a multiple-inheritance-pathway structure. (Another potential hazard is that immediately-following operations might not see the missingval.) Introduced by 95f650674, which split the former coding that used a single pg_attribute update to change both atthasdef and atthasmissing/attmissingval into two updates, but missed that this should entail two CommandCounterIncrements as well. Like that fix, back-patch through v13. Reported-by: Alexander Lakhin <[email protected]> Author: Tender Wang <[email protected]> Reviewed-by: Tom Lane <[email protected]> Discussion: https://postgr.es/m/[email protected] Backpatch-through: 13 Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/bd178960c69bae972c274af8102da9018df8196a Modified Files -------------- src/backend/commands/tablecmds.c | 2 ++ src/test/regress/expected/inherit.out | 15 ++++++++++++++- src/test/regress/sql/inherit.sql | 3 ++- 3 files changed, 18 insertions(+), 2 deletions(-) ^ permalink raw reply [nested|flat] 6+ messages in thread
end of thread, other threads:[~2025-04-02 15:13 UTC | newest] Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2025-04-02 15:13 pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. Tom Lane <[email protected]> 2025-04-02 15:13 pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. Tom Lane <[email protected]> 2025-04-02 15:13 pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. Tom Lane <[email protected]> 2025-04-02 15:13 pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. Tom Lane <[email protected]> 2025-04-02 15:13 pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. Tom Lane <[email protected]> 2025-04-02 15:13 pgsql: Need to do CommandCounterIncrement after StoreAttrMissingVal. Tom Lane <[email protected]>
This inbox is served by agora; see mirroring instructions for how to clone and mirror all data and code used for this inbox