You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Jess Balint (Jira)" <ji...@apache.org> on 2023/02/07 22:34:01 UTC
[jira] [Closed] (CALCITE-5414) Use DateTimeUtils to correctly convert between java.sql types and Unix timestamps
[ https://issues.apache.org/jira/browse/CALCITE-5414?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jess Balint closed CALCITE-5414.
--------------------------------
Resolved in release 1.33.0 (2023-02-06)
> Use DateTimeUtils to correctly convert between java.sql types and Unix timestamps
> ---------------------------------------------------------------------------------
>
> Key: CALCITE-5414
> URL: https://issues.apache.org/jira/browse/CALCITE-5414
> Project: Calcite
> Issue Type: Bug
> Components: core
> Affects Versions: 1.32.0
> Reporter: Gregory Hart
> Assignee: Gregory Hart
> Priority: Major
> Labels: pull-request-available
> Fix For: 1.33.0
>
> Time Spent: 2h 10m
> Remaining Estimate: 0h
>
> Converting java.sql types to unix timestamps requires extra steps to also convert to the correct calendar. Unix timestamps should follow the proleptic Gregorian calendar as defined by ISO-8601. Java uses the standard Gregorian calendar for java.sql types and switches to the Julian calendar for dates before the Gregorian shift.
> The DateTimeUtils class in Avatica correctly handles the calendar conversions. Calcite should use those methods since its own methods do not currently convert between calendars.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)