]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Use index name to determine if an index is for the PK
authorMike Bayer <mike_mp@zzzcomputing.com>
Thu, 25 Jun 2020 15:12:40 +0000 (11:12 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Thu, 25 Jun 2020 16:46:05 +0000 (12:46 -0400)
commite0b5e48796ca2126f4b7d4e8f1a5415ecbfd9acc
treeb5ce06f2ef4c19f916873203634abadb3b5fc835
parentddd1e52423cebd2ea58169b31973c45da8856524
Use index name to determine if an index is for the PK

Fixed bug in Oracle dialect where indexes that contain the full set of
primary key columns would be mistaken as the primary key index itself,
which is omitted, even if there were multiples.  The check has been refined
to compare the name of the primary key constraint against the index name
itself, rather than trying to guess based on the columns present in the
index.

Fixes: #5421
Change-Id: I47c2ccdd0b13977cfd9ef249d4de06371c4fb241
(cherry picked from commit ca56d8dc32f939b2bdb1f590986d4c46d280d186)
doc/build/changelog/unreleased_13/5421.rst [new file with mode: 0644]
lib/sqlalchemy/dialects/oracle/base.py
test/dialect/oracle/test_reflection.py