Details
-
Bug
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
Impala 1.3
-
None
Description
The type error below belongs to the second row to be inserted (sqrt() returns DOUBLE). But the obviously FLOAT first expression gets blamed for the error.
[localhost:21000] > insert overwrite alltypesnopart_insert(float_col) values(CAST(1.0 AS FLOAT)), (sqrt(-1)); Query: insert overwrite alltypesnopart_insert(float_col) values(CAST(1.0 AS FLOAT)), (sqrt(-1)) ERROR: AnalysisException: Possible loss of precision for target table 'functional.alltypesnopart_insert'. Expression 'cast(1.0 as float)' (type: DOUBLE) would need to be cast to FLOAT for column 'float_col'