]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
only use _DMLReturningColFilter for "bulk insert", not other DML
authorMike Bayer <mike_mp@zzzcomputing.com>
Sun, 9 Feb 2025 23:09:21 +0000 (18:09 -0500)
committerMike Bayer <mike_mp@zzzcomputing.com>
Mon, 10 Feb 2025 01:40:30 +0000 (20:40 -0500)
commit1c7e3f9c94b2e6c441ba635a88573bc4cd88ad7d
tree6c062f879bd306a4468d7c000a28c92514346b63
parent9d723b32dbf8d1cd9d7e7ddb47684b9f96fffca8
only use _DMLReturningColFilter for "bulk insert", not other DML

Fixed bug in ORM enabled UPDATE (and theoretically DELETE) where using a
multi-table DML statement would not allow ORM mapped columns from mappers
other than the primary UPDATE mapper to be named in the RETURNING clause;
they would be omitted instead and cause a column not found exception.

Fixes: #12328
Change-Id: I2223ee506eec447823a3a545eecad1a7a03364a9
doc/build/changelog/unreleased_20/12328.rst [new file with mode: 0644]
lib/sqlalchemy/orm/context.py
lib/sqlalchemy/orm/query.py
test/orm/dml/test_update_delete_where.py
test/requirements.py