Aleksandr Efimov created IMPALA-15468:
-----------------------------------------

             Summary: Calcite view alias correction masks validation errors
                 Key: IMPALA-15468
                 URL: https://issues.apache.org/jira/browse/IMPALA-15468
             Project: IMPALA
          Issue Type: Bug
            Reporter: Aleksandr Efimov


Calcite masks view validation errors with ClassCastException in 
ViewAliasCorrector. For t(flag BOOLEAN, ts TIMESTAMP): CREATE VIEW v_sum AS 
SELECT q.n FROM (SELECT SUM(flag) n FROM t) q; SELECT n FROM v_sum; Using 
TRUNC(ts, 'DD') instead of SUM(flag) gives the same crash. Direct expressions 
produce normal AnalysisException. Alias correction assumes every SELECT item is 
a qualified column with AS. The fix checks this shape and preserves unaffected 
items during correction. Reproduced at 2f022a5ca0fc99670bcf197a1f89016cdf78d114 
without planner fallback. Five baseline regressions fail with 
ClassCastException. With the fix, Java build and 18 related Maven tests pass. 
Full upstream precommit and E2E are pending.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to