]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Add DateTime(timezone=True) support to mssql
authorGord Thompson <gord@gordthompson.com>
Sun, 18 Apr 2021 18:15:48 +0000 (12:15 -0600)
committerMike Bayer <mike_mp@zzzcomputing.com>
Tue, 20 Apr 2021 17:13:15 +0000 (13:13 -0400)
commit0c801c8a6617523796f304268d0417a59469a37c
treec70e6103483207a4dba00e3bd831724eb0e8f160
parenta58c99977eafc5f69a3e37f9ddcc328698e7fe1e
Add DateTime(timezone=True) support to mssql

The :paramref:`_types.DateTime.timezone` parameter when set to ``True``
will now make use of the ``DATETIMEOFFSET`` column type with SQL Server
when used to emit DDL, rather than ``DATETIME`` where the flag was silently
ignored.

Fixes: #6306
Change-Id: I4def8337046e8c190d424fa4a259ab24d5f9039e
doc/build/changelog/unreleased_14/6306.rst [new file with mode: 0644]
lib/sqlalchemy/dialects/mssql/base.py
lib/sqlalchemy/dialects/mssql/pyodbc.py
test/dialect/mssql/test_types.py