akashjainn commented on code in PR #26420: URL: https://github.com/apache/datafusion/pull/26420#discussion_r4315898297
########## datafusion/sqllogictest/test_files/parquet.slt: ########## @@ -784,6 +784,120 @@ ERROR: Cast error: Failed to convert -9357363680509551 to datetime for Timestamp statement ok drop table int96_from_spark; +# Without coerce_int96 the timezone has no effect: same type and values as the +# default read above. +statement ok +reset datafusion.execution.parquet.coerce_int96; + +statement ok +CREATE EXTERNAL TABLE int96_from_spark +STORED AS PARQUET +LOCATION '../../parquet-testing/data/int96_from_spark.parquet'; + +query TTT +describe int96_from_spark; +---- +a Timestamp(ns) YES + +query P +select * from int96_from_spark +---- +2024-01-01T20:34:56.123456 +2024-01-01T01:00:00 +1816-03-29T08:56:08.066277376 +2024-12-30T23:00:00 +NULL +1815-11-08T16:01:01.191053312 + +statement ok +drop table int96_from_spark; + +# An explicit nanosecond unit applies the timezone. Review Comment: Fixed here: daaf6e4534e633009e4e362d7317d84351f6f89c. Thank you! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
