Description
Currently, Spark does not resolve star expressions in subqueries correctly. It can only resolve the star expressions using the inner query attributes. For example:
CREATE VIEW t(a) AS VALUES (1), (2);
SELECT * FROM t WHERE a in (SELECT t.*)
SELECT * FROM t, LATERAL (SELECT t.*)
org.apache.spark.sql.AnalysisException: cannot resolve 't.*' given input columns '';
Instead, we should try to resolve star expressions in subquery first using the inner attributes and then using the outer query attributes.
Attachments
Issue Links
- relates to
-
SPARK-34382 ANSI SQL: LATERAL derived table(T491)
-
- Resolved
-
- links to