NET/Connector returns wrong timezone while reading TIMESTAMP field
(Doc ID 2431854.1)
Last updated on AUGUST 14, 2018
Applies to:MySQL Connectors - Version 6.9 and later
Information in this document applies to any platform.
NET/Connector returns wrong timezone while reading TIMESTAMP field. In particular, the mismatch is between time and timezone when TIMESTAMP is read from MySQL database over the MySQL.Data connector.
When reading TIMESTAMP with MySqlDataReader["columnname"], MySQL returns DateTime object with value 2018-06-07 10:00:00 and time zone (DateTime.Kind property value) is set to UTC.
When reading the same TIMESTAMP over MySqlDataReader.GetDateTime("columnname"), MysQL returns DateTime object with value 2018-06-07 10:00:00 and time zone set to Local (this one works as expected).
To view full details, sign in with your My Oracle Support account.
Don't have a My Oracle Support account? Click to get started!