Aggarwal-Raghav commented on PR #6578:
URL: https://github.com/apache/hive/pull/6578#issuecomment-5744304761
> @Aggarwal-Raghav, I don't think we need to support mismatches between
schema and Parquet types; it feels like a hack. Is that supported for ORC?
>
> ```
> CREATE TABLE dummy_string_date (
> id INT,
> col1 STRING
> ) STORED AS PARQUET;
>
> INSERT INTO dummy_string_date VALUES (1, '2026-01-01');
>
> CREATE EXTERNAL TABLE test_parquet_date (
> id INT,
> col1 DATE
> ) STORED AS PARQUET
> LOCATION '${hiveconf:hive.metastore.warehouse.dir}/dummy_string_date';
> ```
>
> @abstractdog, @kasakrisz WDYT ?
I tried on ORC as well:
1. String -> Date working✅
2. String -> Timestamp working✅
3. String -> TimeStampLocalTZ not working❌. Attaching stacktrace as well.
```
Caused by: java.lang.IllegalArgumentException: Unknown type timestamp with
local time zone
at
org.apache.hadoop.hive.ql.io.orc.RecordReaderImpl.nextValue(RecordReaderImpl.java:636)
at
org.apache.hadoop.hive.ql.io.orc.RecordReaderImpl.next(RecordReaderImpl.java:138)
at
org.apache.hadoop.hive.ql.io.orc.OrcInputFormat$OrcRecordReader.next(OrcInputFormat.java:284)
at
org.apache.hadoop.hive.ql.io.orc.OrcInputFormat$OrcRecordReader.next(OrcInputFormat.java:242)
at
org.apache.hadoop.hive.ql.exec.FetchOperator.getNextRow(FetchOperator.java:603)
... 53 more
```
--
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]