[Sqlalchemy-tickets] Issue #4086: mssql TIMESTAMP/ROWVERSION columns is wrong type (zzzeek/sqlalche
Brought to you by:
zzzeek
From: Dan S. <iss...@bi...> - 2017-09-21 19:50:39
|
New issue 4086: mssql TIMESTAMP/ROWVERSION columns is wrong type https://bitbucket.org/zzzeek/sqlalchemy/issues/4086/mssql-timestamp-rowversion-columns-is Dan Stovall: In MSSQL a ROWVERSION or TIMESTAMP column do not contain a date time. Instead the contain an 8-byte integer. Currently, the column is set as sqlachemy.sql.sqltypes.TIMESTAMP, which is an instance of the DateTime type. Running a query against a table with such a column returns a byte string value for those columns. The mssql dialect should probably have a specific ROWVERSION type and it should be an integer, not a DateTime. Also, it would be nice if the values of those columns returned an integer by using int.from_bytes to convert the byte string. |