Question:
https://dev.mysql.com/doc/refman/8.0/en/datetime.html
According to doc, other than TIMESTAMP, date & datetime values are not converted for storage using any time zone. This makes since, since if one uses LocalDate & LocalDateTime in Java, which also doesn't contain any time zone info, and since MySQL says no timezone conversion happens for storing/retreiving date/datetime values, why should I define a timezone to MySQL connection to retrieve those values correctly?
Answer:
The way MySQL Server handles temporal data and temporal data exchanged between a Client and a Server are different things.
The documentation you referred pertains to how MySQL Server stores and retrieves temporal data and if some kind of TZ adjustments occur in the process. For example, suppose the server is configured with TZ UTC+02:00 and you store the same instant X in a TIMESTAMP column and a DATETIME column; when you retrieve the same data you'll see the same instant X values, but if you change the serv