Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python polars write database Time zone issue #20980

Open
2 tasks done
Sankartk opened this issue Jan 29, 2025 · 0 comments
Open
2 tasks done

Python polars write database Time zone issue #20980

Sankartk opened this issue Jan 29, 2025 · 0 comments
Labels
bug Something isn't working needs triage Awaiting prioritization by a maintainer python Related to Python Polars

Comments

@Sankartk
Copy link

Checks

  • I have checked that this issue has not already been reported.
  • I have confirmed this bug exists on the latest version of Polars.

Reproducible example

Hi, I have a question about the Python polars write_database method. I am having a parquet file with a date time column with value as 2024-08-08 18:03:05.012 EDT. When using the write_database method, the data is getting written as 2024-08-08 17:03:05.012. The database Time zone is set as America/New_York. Similarly for the same date time when I want to store as a date, in the parquet is getting correctly transformed as 2024-08-08 00:00:00 EDT but it is getting written as 2024-07-08 in the dayabase. The database is Aurora Postgres. Is there any work around for this ? Please let me know.

Log output

Issue description

Hi, I have a question about the Python polars write_database method. I am having a parquet file with a date time column with value as 2024-08-08 18:03:05.012 EDT. When using the write_database method, the data is getting written as 2024-08-08 17:03:05.012. The database Time zone is set as America/New_York. Similarly for the same date time when I want to store as a date, in the parquet is getting correctly transformed as 2024-08-08 00:00:00 EDT but it is getting written as 2024-07-08 in the dayabase. The database is Aurora Postgres. Is there any work around for this ? Please let me know.

Expected behavior

Expected behavior is to write the time as is from parquet file

Installed versions

Polars version 1.4.1

@Sankartk Sankartk added bug Something isn't working needs triage Awaiting prioritization by a maintainer python Related to Python Polars labels Jan 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs triage Awaiting prioritization by a maintainer python Related to Python Polars
Projects
None yet
Development

No branches or pull requests

1 participant