Questions tagged [timezone]
A time zone is a region on Earth that has a uniform, legally mandated standard time. It is often represented by an identifier, such as "America/Los_Angeles". Note that a numeric modifier such as "-07:00" is an _offset_. A time zone encodes additional details like Daylight Saving Time.
150 questions
0 votes
1 answer
50 views
Postgresql giving different result when comparing timestamp with date in different time zone
When running the following query, I would expect it to give the same result independently of the session time zone but instead it gives different result depending on the session: select '2025-09-22' &...
1 vote
1 answer
202 views
Alter timestamptz column to timestamp, without re-writing the table
I'm using Postgres Debezium source connectors, which does not support columns with timezone. I want to convert a table column from type from timestamptz to timestamp. Postgres table stores data in UTC ...
0 votes
1 answer
221 views
Postgres unexpected results with time zone conversions
I am doing some imports of data that includes time zone conversion. Data that I am importing is in America/New_York timezone and I have to import it as UTC timestamp. I tried some examples I found on ...
0 votes
1 answer
133 views
MySQL timezone tables: mysql_tzinfo_to_sql docs are incorrect
A basic installation of MySQL creates, but does not populate, the several timezone-related tables in database "mysql". To populate those tables, you might consult: https://dev.mysql.com/doc/...
0 votes
0 answers
136 views
Relationship between /etc/localtime and Etc/UTC in PostgreSQL
I run our company's DBMS in containers, and when creating a container, the ansible deployment role mounts the host file /etc/localtime along the same path into the container (although, as far as I ...
1 vote
0 answers
160 views
InfluxDB not returning results when group by time offset at a summer/winter time change
Let's start with an example. I've got an application that logs a point every minute. When I aggregate this data into a query where I'll have the count of logs per day, I get the following result. Keep ...
0 votes
1 answer
51 views
Postgres: any traps when adding tables with `timestamptz` fields, when existing tables all use `timestamp`?
Similarly as in Convert Postgres TIMESTAMP to TIMESTAMPTZ, but with the difference that I don't plan to modify existing table's timestamp columns. Are there any gotchas when using timestamptz for new ...
1 vote
0 answers
310 views
is it possible to set specific timezone for session in mariadb connector/j
I 'm trying to use timezone setting with mariadb connector/J version 3.x. In the documentation,in Timezone consideration, it says: 'a timezone': connector will set connection variable to value. ...
0 votes
1 answer
4k views
Postgres changing data type from timestamp to timestamptz (with time zone)
I recognize there are some similar questions, and I've read quite a few, so pardon me if I just missed the answer. I have data that was stored as a TIMESTAMP data type, but now we want it to be stored ...
0 votes
0 answers
3k views
TimeZone Setting On PostgreSQL Databases
I have a Patroni cluster with two Ubuntu 22 db server. The timezone of my instances was set to UTC. I have needed to edit them to set the local timezone to Europe/Istanbul. I have made the timezone ...
0 votes
0 answers
136 views
MySQL System Timezone using Abbreviation (AST) vs Olson Timezone (America/Curacao)
I am working on a MySQL 5.7.41-44 instance running on a CentOS server. The Linux timezone (per timedatectl) is America/Curacao (AST, -0400). The MySQL @@system_time_zone returns AST (and not America/...
0 votes
1 answer
65 views
How to express dates for display in neighboring timezones?
I run a toy database where users can browse around, find toys they own, and "add them to their collection". On the back end, I add a row to a dedicated MYSQL table with data about the ...
0 votes
1 answer
1k views
How to get current date and time in Elasticsearch
I need to review the current date and time zone from Elasticsearch. I'm checking the elastic documentation and it mentioned that the default value is UTC. In other environments I use: SELECT NOW(); ...
1 vote
1 answer
2k views
Find rows between two timestamps -- timezone conversion problems
I have a column called time_utc. This is of type timestamp, but it's important to note that the date is always January 1 2023, but at varying times. I want to return the rows where time_utc is between ...
0 votes
1 answer
2k views
Does changing server time zone "shift" SQL Server stored date / time values in ODBC / JDBC?
I've read that SQL Server: uses system time zone on Windows (reg key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation\TimeZoneKeyName) uses TZ env var on Linux or /etc/timezone....