You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Apache Spark (Jira)" <ji...@apache.org> on 2022/07/04 14:03:00 UTC

[jira] [Commented] (SPARK-39672) NotExists subquery failed with conflicting attributes

    [ https://issues.apache.org/jira/browse/SPARK-39672?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17562190#comment-17562190 ] 

Apache Spark commented on SPARK-39672:
--------------------------------------

User 'manuzhang' has created a pull request for this issue:
https://github.com/apache/spark/pull/37074

> NotExists subquery failed with conflicting attributes
> -----------------------------------------------------
>
>                 Key: SPARK-39672
>                 URL: https://issues.apache.org/jira/browse/SPARK-39672
>             Project: Spark
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 3.1.3
>            Reporter: Manu Zhang
>            Priority: Major
>
> {code:sql}
> select * from
> (
> select v1.a, v1.b, v2.c
> from v1
> inner join v2
> on v1.a=v2.a) t3
> where not exists (
>   select 1
>   from v2
>   where t3.a=v2.a and t3.b=v2.b and t3.c=v2.c
> ){code}
> This query throws AnalysisException
> {code:java}
> org.apache.spark.sql.AnalysisException: Found conflicting attributes a#266 in the condition joining outer plan:
>   Join Inner, (a#250 = a#266)
> :- Project [_1#243 AS a#250, _2#244 AS b#251]
> :  +- LocalRelation [_1#243, _2#244, _3#245]
> +- Project [_1#259 AS a#266, _3#261 AS c#268]
>    +- LocalRelation [_1#259, _2#260, _3#261]and subplan:
>   Project [1 AS 1#273, _1#259 AS a#266, _2#260 AS b#267, _3#261 AS c#268#277]
> +- LocalRelation [_1#259, _2#260, _3#261] {code}



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

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org