Details
-
Bug
-
Status: Resolved
-
Blocker
-
Resolution: Fixed
-
Impala 2.0
-
None
-
None
-
commit 53b73e5b4dd11888ab3c86d5d331a652f51f8092
Author: Skye Wanderman-Milne <skye@cloudera.com>
Date: Tue Sep 30 11:09:21 2014 -0700
Revert "Free local UDF/UDA allocations"
Description
Something strange happens with the query below that results in Impala thinking that the query is invalid. It complains about types being incompatible but the columns mentioned in the error are never used together in the query.
[localhost.localdomain:21000] > SELECT 1 FROM alltypesagg t1 INNER JOIN alltypesagg t2 ON t2.date_string_col = t1.string_col AND t2.id = t1.day LEFT JOIN alltypesagg t3 ON t3.id = t2.id AND t3.string_col = t2.date_string_col; Query: explain SELECT 1 FROM alltypesagg t1 INNER JOIN alltypesagg t2 ON t2.date_string_col = t1.string_col AND t2.id = t1.day LEFT JOIN alltypesagg t3 ON t3.id = t2.id AND t3.string_col = t2.date_string_col ERROR: IllegalStateException: com.cloudera.impala.common.AnalysisException: Incompatible return types 'STRING' and 'INT' of exprs 't1.string_col' and 't3.id'. CAUSED BY: AnalysisException: Incompatible return types 'STRING' and 'INT' of exprs 't1.string_col' and 't3.id'.
The query runs fine in Postgresql but returns no rows
functional=# SELECT 1 functional-# FROM alltypesagg t1 functional-# INNER JOIN alltypesagg t2 ON functional-# t2.date_string_col = t1.string_col functional-# AND t2.id = t1.day functional-# LEFT JOIN alltypesagg t3 ON functional-# t3.id = t2.id functional-# AND t3.string_col = t2.date_string_col; ?column? ---------- (0 rows)