E.6.3.2.1. Constraints

From: PG Doc comments form <noreply(at)postgresql(dot)org>
To: pgsql-docs(at)lists(dot)postgresql(dot)org
Cc: kacperkuras(at)hotmail(dot)com
Subject: E.6.3.2.1. Constraints
Date: 2026-09-19 14:49:55
Message-ID: 178982939588.1243.6087398342138761960@wrigleys.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-docs

The following documentation comment has been logged on the website:

Page: https://www.postgresql.org/docs/18/release-18.html
Description:

Commit 086c84b23 changed what a foreign key with ON DELETE RESTRICT or ON
UPDATE RESTRICT raises when it refuses a change: SQLSTATE 23001
(restrict_violation) instead of 23503 (foreign_key_violation), and the
message now says "violates RESTRICT setting of foreign key constraint". The
PostgreSQL 18 release notes do not mention it.

Code that catches 23503 to report that a row is still referenced stops
matching RESTRICT keys after upgrading, while NO ACTION keys still raise
23503. The same notes list the change to the XML error codes (cd838e200), so
this one seems to belong there as well.

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message Ken Harris 2026-09-20 18:36:23 Re: Anonymous record member access
Previous Message David G. Johnston 2026-09-19 13:55:27 Re: 9.4.1. format