[
https://issues.apache.org/jira/browse/DRILL-4582?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Volodymyr Vysotskyi resolved DRILL-4582.
----------------------------------------
Resolution: Fixed
Fix Version/s: 1.12.0
Fixed in the scope of DRILL-5717.
> TestCastFunctions#testToDateForTimeStamp returns error by timezone difference
> -----------------------------------------------------------------------------
>
> Key: DRILL-4582
> URL: https://issues.apache.org/jira/browse/DRILL-4582
> Project: Apache Drill
> Issue Type: Bug
> Components: Functions - Drill
> Affects Versions: 1.7.0
> Reporter: Jihun Kang
> Priority: Minor
> Fix For: 1.12.0
>
>
> When running drill tests on a machine with positive offsets of timezone,
> following error is created. This error comes from the joda datetime, because
> joda datetime create an object with default timezone.
> {noformat}
> Running org.apache.drill.exec.fn.impl.TestCastFunctions#testToDateForTimeStamp
> java.lang.Exception: at position 0 column '`col`' mismatched values,
> expected: 1969-12-31T00:00:00.000+09:00(DateTime) but received
> 1970-01-01T00:00:00.000+09:00(DateTime)
> Expected Records near verification failure:
> Record Number: 0 { `col` : 1969-12-31T00:00:00.000+09:00, }
> Actual Records near verification failure:
> Record Number: 0 { `col` : 1970-01-01T00:00:00.000+09:00, }
> For query: select to_date(to_timestamp(-1)) as col
> from (values(1))
> at
> org.apache.drill.DrillTestWrapper.compareMergedOnHeapVectors(DrillTestWrapper.java:436)
> at
> org.apache.drill.DrillTestWrapper.compareOrderedResults(DrillTestWrapper.java:390)
> at org.apache.drill.DrillTestWrapper.run(DrillTestWrapper.java:126)
> at
> org.apache.drill.exec.fn.impl.TestCastFunctions.testToDateForTimeStamp(TestCastFunctions.java:74)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at java.lang.reflect.Method.invoke(Method.java:606)
> Caused by: java.lang.Exception: at position 0 column '`col`' mismatched
> values, expected: 1969-12-31T00:00:00.000+09:00(DateTime) but received
> 1970-01-01T00:00:00.000+09:00(DateTime)
> Expected Records near verification failure:
> Record Number: 0 { `col` : 1969-12-31T00:00:00.000+09:00, }
> Actual Records near verification failure:
> Record Number: 0 { `col` : 1970-01-01T00:00:00.000+09:00, }
> at
> org.apache.drill.DrillTestWrapper.compareMergedVectors(DrillTestWrapper.java:174)
> at
> org.apache.drill.DrillTestWrapper.compareMergedOnHeapVectors(DrillTestWrapper.java:434)
> ... 7 more
> Caused by: java.lang.Exception: at position 0 column '`col`' mismatched
> values, expected: 1969-12-31T00:00:00.000+09:00(DateTime) but received
> 1970-01-01T00:00:00.000+09:00(DateTime)
> at
> org.apache.drill.DrillTestWrapper.compareValuesErrorOnMismatch(DrillTestWrapper.java:552)
> at
> org.apache.drill.DrillTestWrapper.compareMergedVectors(DrillTestWrapper.java:172)
> ... 8 more
> {noformat}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)