This issue arises in v.0.3.2
Suppose a Clickhouse server is located in UTC+0 timezone, while the client is on UTC-x timezone.
Then the following query
SELECT toDate('2022-10-27')
will return 2022-10-26 on the client side.
It seems that somewhere inside Java the date '2022-10-27' turns into '2022-10-27 00:00:00 UTC', which is the same as '2022-10-26 20:00:00 NY(UTC-4)', and the latter converts to '2022-10-26'.
Legacy version (v.0.2.6) works fine by the way.
This issue arises in v.0.3.2
Suppose a Clickhouse server is located in UTC+0 timezone, while the client is on UTC-x timezone.
Then the following query
will return
2022-10-26on the client side.It seems that somewhere inside Java the date '2022-10-27' turns into '2022-10-27 00:00:00 UTC', which is the same as '2022-10-26 20:00:00 NY(UTC-4)', and the latter converts to '2022-10-26'.
Legacy version (v.0.2.6) works fine by the way.