]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
consider indpendent CTE for UPDATE..FROM
authorMike Bayer <mike_mp@zzzcomputing.com>
Tue, 3 Oct 2023 12:40:06 +0000 (08:40 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Tue, 3 Oct 2023 17:29:01 +0000 (13:29 -0400)
commita2804c621961231b0cc3d9b4f2893417d460e447
tree885943b2e11456c91f35dde20a2d618debbc5085
parentaa7f15de35fa076afa2a7be2e3c3e030986f5a86
consider indpendent CTE for UPDATE..FROM

Fixed issue where referring to a FROM entry in the SET clause of an UPDATE
statement would not include it in the FROM clause of the UPDATE statement,
if that entry were nowhere else in the statement; this occurs currently for
CTEs that were added using :meth:`.Update.add_cte` to provide the desired
CTE at the top of the statement.

Fixes: #10408
Change-Id: I6e3c6ca7a00cc884bda7e0f24c62c34c75134e5b
doc/build/changelog/unreleased_20/10408.rst [new file with mode: 0644]
lib/sqlalchemy/sql/dml.py
test/sql/test_cte.py