HIVE-29695: ClassCastException in MapJoin when Parquet String is mapped to Date#6578
HIVE-29695: ClassCastException in MapJoin when Parquet String is mapped to Date#6578Aggarwal-Raghav wants to merge 1 commit into
Conversation
|
@deniskuzZ , need some advice here. In the q file present in this PR, if i enable vectorization then it is failing with the following error. I observed the original stacktrace in hive-sever2.err in prod in Hive 4.0.1 (Not sure if user has disabled vectorization at beeline session but this is my best guess). I think work done similar to HIVE-29649, needs to be done if we want to enable String to Date vectorized conversion? |
|
|
| id INT, | ||
| col1 DATE | ||
| ) STORED AS PARQUET | ||
| LOCATION '${hiveconf:hive.metastore.warehouse.dir}/repro_parquet_string'; |
There was a problem hiding this comment.
we can use ALTER also instead of creating a new table on top of previously created table repro_parquet_string. The goal was to pass String to DATE col
| INSERT INTO small_table VALUES (1, '2026-01-01'); | ||
|
|
||
| SET hive.auto.convert.join=true; | ||
| SET hive.vectorized.execution.enabled=false; |
There was a problem hiding this comment.
is that only reproduced in non-vectorized flow ?
┌─────────────────────────────┬──────────────────────────────────────────────────────────┐
│ Path │ Where string-source conversions live │
├─────────────────────────────┼──────────────────────────────────────────────────────────┤
│ Row-by-row (non-vectorized) │ ETypeConverter.ESTRING_CONVERTER │
├─────────────────────────────┼──────────────────────────────────────────────────────────┤
│ Vectorized │ ParquetDataColumnReaderFactory.TypesFromStringPageReader │
└─────────────────────────────┴──────────────────────────────────────────────────────────┘
There was a problem hiding this comment.
yes, when enabled the above exception in comments is thrown.



What changes were proposed in this pull request?
Adds the missing DATE case to ESTRING_CONVERTER in ETypeConverter.java to properly parse the Parquet string and return a DateWritableV2
Why are the changes needed?
To fix the
Does this PR introduce any user-facing change?
NO
How was this patch tested?
Wrote a Junit test and q file