Description
From the information I've gathered it looks like currently there is no way to specify timezone at connection level. This means that you need to manually prepend SET time_zone = '+00:00';
to every SQL query, assuming one would want to operate in UTC. Setting timezone is a very important thing when you're dealing with TIMESTAMP
fields, since mysql automatically converts them:
MySQL converts TIMESTAMP values from the current time zone to UTC for storage, and back from UTC to the current time zone for retrieval.
Would it be a good idea to add appropriate option to connection string in order to allow specifying timezone that should be used for the connection by default? I believe this setting is general enough to be included on connection level and it'd be a good idea to specify default timezone that can still be overridden by appropriate SET time_zone
SQL instruction, if one would like.
Thanks.