]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
set unique=False on indexes
authorMike Bayer <mike_mp@zzzcomputing.com>
Tue, 30 Apr 2024 13:28:07 +0000 (09:28 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Tue, 30 Apr 2024 13:28:07 +0000 (09:28 -0400)
References: https://github.com/sqlalchemy/sqlalchemy/discussions/11339
Change-Id: Ia4adc2d5911926fdd1896cc561d511bdd647732d

examples/versioned_history/history_meta.py

index 3f26832b9edfad01c78635d765e63777e5d7dc35..e4c102c0ad0b9ad205ed12a85f5c3f2c60d93193 100644 (file)
@@ -59,6 +59,7 @@ def _history_mapper(local_mapper):
         for idx in history_table.indexes:
             if idx.name is not None:
                 idx.name += "_history"
+            idx.unique = False
 
         for orig_c, history_c in zip(
             local_mapper.local_table.c, history_table.c