Details
-
Improvement
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
Impala 3.0, Impala 2.12.0, Impala 3.1.0, Impala 3.2.0, Impala 3.3.0
-
None
-
ghx-label-4
Description
Tables for test:
CREATE TABLE test_a ( id STRING, val STRING ); CREATE TABLE test_b ( id STRING, val STRING );
Bound predicates optimization (implement in Analyzer::getBoundPredicates) works for this sql:
EXPLAIN
SELECT count(*) FROM test_a a
LEFT JOIN
(SELECT * FROM test_b) b
ON a.id=b.id
WHERE upper(b.val)='123';
But does't work for this one:
EXPLAIN
SELECT count(*) FROM test_a a
LEFT JOIN
(SELECT *, upper(val) AS upper_val FROM test_b) b
ON a.id=b.id
WHERE upper_val='123';