You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Jesus Camacho Rodriguez (JIRA)" <ji...@apache.org> on 2017/06/20 13:13:02 UTC
[jira] [Updated] (CALCITE-1832) DateTimeUtils dateString to Unix
translation error
[ https://issues.apache.org/jira/browse/CALCITE-1832?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jesus Camacho Rodriguez updated CALCITE-1832:
---------------------------------------------
Fix Version/s: 1.13.0
> DateTimeUtils dateString to Unix translation error
> --------------------------------------------------
>
> Key: CALCITE-1832
> URL: https://issues.apache.org/jira/browse/CALCITE-1832
> Project: Calcite
> Issue Type: Bug
> Components: avatica
> Affects Versions: 1.10.0
> Reporter: Stefano Bortoli
> Fix For: 1.13.0
>
>
> Using the latest snapshot of Calcite, one of the Apache Flink Test fails. The failure is due to an error in CAST, that relies on Avatica DateTimeUtils.
> I have implemented a simple class test:
> {code}
> public class Test
> {
> public static void main( String[] args )
> {
> int dateInt = DateTimeUtils.dateStringToUnixDate("1500-03-04");
> System.out.println(dateInt);
> System.out.println(DateTimeUtils.unixDateToString(dateInt));
>
> }
> }
> {code}
> and the output is:
> {code}
> -171592
> 1500-03-14
> {code}
> it adds an offset of 10 days for some reason.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)