Repository navigation
Have chDB use postgres session's TimeZone - #101
Merged
Merged
Conversation
serprex
force-pushed
the
session-timezone
branch
3 times, most recently
from
October 7, 2026 05:46
d26c82b to
68500b6
Compare
serprex
marked this pull request as ready for review
October 7, 2026 17:51
serprex
force-pushed
the
session-timezone
branch
from
October 7, 2026 18:06
68500b6 to
6b04c61
Compare
theory
approved these changes
Oct 7, 2026
| CREATE TABLE naive (id INT, ts TEXT, tstz TEXT); | ||
| INSERT INTO naive VALUES (1, '2026-08-28 12:00:00', '2026-08-28 12:00:00'); | ||
| COPY naive TO :'naive_url'; | ||
| SET timezone TO 'America/Los_Angeles'; |
Collaborator
There was a problem hiding this comment.
This is the default in pg_regress, FWIW.
serprex
force-pushed
the
session-timezone
branch
from
October 7, 2026 19:02
6b04c61 to
d94c9b2
Compare
theory
reviewed
Oct 7, 2026
`timestamp without timezone` columns currently parses as UTC, then shifts into PostgreSQL session TimeZone. eg noon under America/Los_Angeles during DST produces 05:00 Setting session_timezone on CH, and not defining destination type with explicit UTC, preserves Postgres TimeZone on CH
serprex
force-pushed
the
session-timezone
branch
from
October 7, 2026 19:25
d94c9b2 to
f29444f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
depends on ClickHouse/pg-clickhouse-c/pull/39
timestamp without timezonecolumns currently parses as UTC, then shifts into PostgreSQL session TimeZone. eg noon underAmerica/Los_Angelesduring DST produces05:00Setting session_timezone on CH, and not defining destination type with explicit UTC, preserves Postgres TimeZone on CH