pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Revert structural changes to not-null constraints
Date: Mon, 13 May 2024 10:23:30 +0000
Message-ID: <E1s6Sq9-000kcQ-Ip@gemulon.postgresql.org> (raw)

Revert structural changes to not-null constraints

There are some problems with the new way to handle these constraints
that were detected at the last minute, and require fixes that appear too
invasive to be doing this late in the cycle.  Revert this (again) for
now, we'll try again with these problems fixed.

The following commits are reverted:

    b0e96f311985  Catalog not-null constraints
    9b581c534186  Disallow changing NO INHERIT status of a not-null constraint
    d0ec2ddbe088  Fix not-null constraint test
    ac22a9545ca9  Move privilege check to the right place
    b0f7dd915bca  Check stack depth in new recursive functions
    3af721794272  Update information_schema definition for not-null constraints
    c3709100be73  Fix propagating attnotnull in multiple inheritance
    d9f686a72ee9  Fix restore of not-null constraints with inheritance
    d72d32f52d26  Don't try to assign smart names to constraints
    0cd711271d42  Better handle indirect constraint drops
    13daa33fa5a6  Disallow NO INHERIT not-null constraints on partitioned tables
    d45597f72fe5  Disallow direct change of NO INHERIT of not-null constraints
    21ac38f498b3  Fix inconsistencies in error messages

Discussion: https://postgr.es/m/202405110940.joxlqcx4dogd@alvherre.pgsql

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/6f8bb7c1e9610dd7af20cdaf74c4ff6e6d678d44

Modified Files
--------------
contrib/sepgsql/expected/alter.out                 |    3 +
contrib/sepgsql/expected/ddl.out                   |    2 -
contrib/test_decoding/expected/ddl.out             |   12 -
doc/src/sgml/catalogs.sgml                         |   13 +-
doc/src/sgml/ddl.sgml                              |   55 +-
doc/src/sgml/ref/alter_table.sgml                  |   13 +-
doc/src/sgml/ref/create_table.sgml                 |    8 +-
src/backend/catalog/heap.c                         |  386 +----
src/backend/catalog/information_schema.sql         |   71 +-
src/backend/catalog/pg_constraint.c                |  441 +-----
src/backend/commands/tablecmds.c                   | 1664 +++++---------------
src/backend/optimizer/util/plancat.c               |    2 -
src/backend/parser/gram.y                          |   19 +-
src/backend/parser/parse_utilcmd.c                 |  288 +---
src/backend/utils/adt/ruleutils.c                  |   22 -
src/backend/utils/cache/relcache.c                 |   42 +-
src/bin/pg_dump/common.c                           |   19 +-
src/bin/pg_dump/pg_dump.c                          |  322 +---
src/bin/pg_dump/pg_dump.h                          |    9 +-
src/bin/pg_dump/t/002_pg_dump.pl                   |   10 +-
src/bin/psql/describe.c                            |   44 -
src/include/catalog/catversion.h                   |    2 +-
src/include/catalog/heap.h                         |    8 +-
src/include/catalog/pg_constraint.h                |    7 -
src/include/nodes/parsenodes.h                     |   11 +-
.../test_ddl_deparse/expected/alter_table.out      |   18 +-
.../test_ddl_deparse/expected/create_table.out     |   26 +-
.../modules/test_ddl_deparse/test_ddl_deparse.c    |    6 +-
src/test/regress/expected/alter_table.out          |   24 +-
src/test/regress/expected/cluster.out              |    7 +-
src/test/regress/expected/constraints.out          |  518 ------
src/test/regress/expected/create_table.out         |   35 +-
src/test/regress/expected/create_table_like.out    |   10 -
src/test/regress/expected/event_trigger.out        |    2 -
src/test/regress/expected/foreign_data.out         |  108 +-
src/test/regress/expected/foreign_key.out          |   16 +-
src/test/regress/expected/generated.out            |    2 -
src/test/regress/expected/identity.out             |    4 -
src/test/regress/expected/indexing.out             |   38 +-
src/test/regress/expected/inherit.out              |  510 ------
src/test/regress/expected/partition_merge.out      |    2 -
src/test/regress/expected/publication.out          |    6 -
src/test/regress/expected/replica_identity.out     |   24 -
src/test/regress/expected/rowsecurity.out          |    2 -
src/test/regress/sql/alter_table.sql               |   12 +-
src/test/regress/sql/constraints.sql               |  217 ---
src/test/regress/sql/indexing.sql                  |    5 +-
src/test/regress/sql/inherit.sql                   |  229 ---
src/test/regress/sql/replica_identity.sql          |   15 -
49 files changed, 709 insertions(+), 4600 deletions(-)



Message-ID: <E1s6Sq9-000kcQ-Ip@gemulon.postgresql.org>
Permalink:  ../E1s6Sq9-000kcQ-Ip@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1s6Sq9-000kcQ-Ip@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: alvherre@alvh.no-ip.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Revert structural changes to not-null constraints
  In-Reply-To: <E1s6Sq9-000kcQ-Ip@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox