diff options
author | Federico Caselli <cfederico87@gmail.com> | 2020-08-22 00:30:44 +0200 |
---|---|---|
committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2020-08-22 12:46:12 -0400 |
commit | 9ab4da7018eae8fc86430c24a38f8ffb0a5951ab (patch) | |
tree | d6f9e401cbc24a3beb11a9fec56dd17f89cfe6fe /lib/sqlalchemy/dialects/postgresql/base.py | |
parent | 317f2e1be2b06cdc12bc84510eb743d9752763dd (diff) | |
download | sqlalchemy-9ab4da7018eae8fc86430c24a38f8ffb0a5951ab.tar.gz |
Updates for MariaDB sequences
MariaDB should not run a Sequence if it has optional=True.
Additionally, rework the rules in crud.py to accommodate the
new combination MariaDB brings us, which is a dialect
that supports both cursor.lastrowid, explicit sequences,
*and* no support for returning.
Co-authored-by: Mike Bayer <mike_mp@zzzcomputing.com>
Fixes: #5528
Change-Id: I9a8ea69a34983affa95dfd22186e2908fdf0d58c
Diffstat (limited to 'lib/sqlalchemy/dialects/postgresql/base.py')
-rw-r--r-- | lib/sqlalchemy/dialects/postgresql/base.py | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/lib/sqlalchemy/dialects/postgresql/base.py b/lib/sqlalchemy/dialects/postgresql/base.py index 53c54ab65..07405e6d1 100644 --- a/lib/sqlalchemy/dialects/postgresql/base.py +++ b/lib/sqlalchemy/dialects/postgresql/base.py @@ -2526,7 +2526,6 @@ class PGExecutionContext(default.DefaultExecutionContext): elif column.default is None or ( column.default.is_sequence and column.default.optional ): - # execute the sequence associated with a SERIAL primary # key column. for non-primary-key SERIAL, the ID just # generates server side. |