]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
allow control of constraint isolation w/ add/drop constraint
authorMike Bayer <mike_mp@zzzcomputing.com>
Thu, 27 Feb 2025 17:04:12 +0000 (12:04 -0500)
committerMike Bayer <mike_mp@zzzcomputing.com>
Thu, 27 Feb 2025 19:48:03 +0000 (14:48 -0500)
commitd6f11d9030b325d5afabf87869a6e3542edda54b
tree6e98988a708607985fc864c73e820e78097e2cd6
parent402f3b3e1e1c4bf1fe4065a60d6867ea03f3fa34
allow control of constraint isolation w/ add/drop constraint

Added new parameters :paramref:`.AddConstraint.isolate_from_table` and
:paramref:`.DropConstraint.isolate_from_table`, defaulting to True, which
both document and allow to be controllable the long-standing behavior of
these two constructs blocking the given constraint from being included
inline within the "CREATE TABLE" sequence, under the assumption that
separate add/drop directives were to be used.

Fixes: #12382
Change-Id: I53c4170ccb5803f69945ba7aa3d3a143131508eb
doc/build/changelog/unreleased_20/12382.rst [new file with mode: 0644]
lib/sqlalchemy/sql/ddl.py
test/sql/test_constraints.py