Re: BUG #19393: pg_upgrade fails with duplicate key violation when CHECK constraint named *_not_null exists

From: Hüseyin Demir <huseyin(dot)d3r(at)gmail(dot)com>
To: pgsql-hackers(at)lists(dot)postgresql(dot)org
Cc: Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>
Subject: Re: BUG #19393: pg_upgrade fails with duplicate key violation when CHECK constraint named *_not_null exists
Date: 2026-02-20 06:52:33
Message-ID: 177157035357.626.5599596504298221780.pgcf@coridan.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

The following review has been posted through the commitfest application:
make installcheck-world: tested, failed
Implements feature: tested, failed
Spec compliant: tested, failed
Documentation: tested, failed

Hi,

I reviewed and tested v2 of this patch.

Builds with zero errors and zero warnings and all tests passed.

Verified the fix against Bug #19393. The original crash (unique key violation on pg_constraint_conrelid_contypid_conname_index) no longer occurs.
Also tested edge cases: cascading collisions (name, name1, name2 all taken), multiple NOT NULL columns with mixed collisions, and the normal no-collision case. All work
correctly. No doc changes needed.

The new status of this patch is: Ready for Committer

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Richard Guo 2026-02-20 09:57:12 Re: BUG #19412: Wrong query result with not null constraint
Previous Message Tom Lane 2026-02-19 18:25:48 Re: BUG #19412: Wrong query result with not null constraint

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2026-02-20 07:58:39 Re: Patch for migration of the pg_commit_ts directory
Previous Message Amit Kapila 2026-02-20 06:48:02 Re: [PATCH] Support automatic sequence replication