Skip to content

Wrong Default value of TimeZone in the duckdb settings  #1897

@ujaval403

Description

@ujaval403

What happens?

The TimeZone value in settings is in UTC+XXXX or UTC-XXXX which is not supported value in the timezone
so we are not getting expected values in query results.

https://duckdb.org/docs/sql/data_types/timezones.html

To Reproduce

Screen.Recording.2024-10-15.at.7.05.48.AM.mp4
install icu;
load icu;

CREATE or REPLACE TABLE events (
   id INTEGER,
   event_time TIMESTAMPTZ
);

insert into events values (1, epoch_ms(1680308400000)); -- 1 April 2023 12:20:00 AM UTC

select *, date_trunc('month', event_time) from events;

to check the current value

select * from duckdb_settings() where name='TimeZone';

Right Result after

set TimeZone = 'America/Los_Angeles';

select *, date_trunc('month', event_time) from events;

Browser/Environment:

129.0.6668.100

Device:

Mac OS

DuckDB-Wasm Version:

1.28.1-dev258.0

DuckDB-Wasm Deployment:

Custom

Full Name:

Ujaval Bhatt

Affiliation:

DevRev

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions