Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Duplicate
-
None
-
None
-
None
Description
Not sure if this is related to DRILL-2249, since the error seems to be different.
On today's master commit:
select commit_id from sys.version;
------------
commit_id |
------------
4ed0a8d68ec5ef344fb54ff7c9d857f7f3f153aa |
------------
If I create a parquet file containing decimal types, using the following CTAS
create table my_dec_table as select cast(l_quantity as decimal(10,2)) dec1, cast(l_discount as decimal(10,2)) dec2, cast(l_tax as decimal(10,2)) as dec3 from cp.`tpch/lineitem.parquet` ; +------------+---------------------------+ | Fragment | Number of records written | +------------+---------------------------+ | 0_0 | 60175 | +------------+---------------------------+ 1 row selected (1.71 seconds)
Then, if I want to query this new parquet file with :
select * from my_dec_table; RemoteRpcException: Failure while running fragment., org.apache.drill.exec.vector.Decimal18Vector cannot be cast to org.apache.drill.exec.vector.BigIntVector [ de164ae4-2d2b-4257-bafb-3ca5165678f9 on 10.250.0.8:31010 ] [ de164ae4-2d2b-4257-bafb-3ca5165678f9 on 10.250.0.8:31010 ] select dec1, dec2, dec3 from my_dec_table; Query failed: RemoteRpcException: Failure while running fragment., org.apache.drill.exec.vector.Decimal18Vector cannot be cast to org.apache.drill.exec.vector.BigIntVector [ 0f5b41c3-1ab3-43b4-9742-cea622d3f476 on 10.250.0.8:31010 ] [ 0f5b41c3-1ab3-43b4-9742-cea622d3f476 on 10.250.0.8:31010 ]
parquet-tools shows the following schema information for the generated parquet file:
message root { required int64 dec1 (DECIMAL(10,2)); required int64 dec2 (DECIMAL(10,2)); required int64 dec3 (DECIMAL(10,2)); }
Attachments
Issue Links
- is duplicated by
-
DRILL-2262 selecting columns of certain datatypes from a dictionary encoded parquet file created by drill fails
- Resolved