[ https://issues.apache.org/jira/browse/SPARK-18063?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15597304#comment-15597304 ]
Apache Spark commented on SPARK-18063: -------------------------------------- User 'jiangxb1987' has created a pull request for this issue: https://github.com/apache/spark/pull/15597 > Failed to infer constraints over multiple aliases > ------------------------------------------------- > > Key: SPARK-18063 > URL: https://issues.apache.org/jira/browse/SPARK-18063 > Project: Spark > Issue Type: Bug > Components: SQL > Reporter: Jiang Xingbo > Priority: Minor > > The `UnaryNode.getAliasedConstraints` function fails to replace all > expressions by their alias where constraints contains more than one > expression to be replaced. For example: > {code} > val tr = LocalRelation('a.int, 'b.string, 'c.int) > val multiAlias = tr.where('a === 'c + 10).select('a.as('x), 'c.as('y)) > multiAlias.analyze.constraints > {code} > currently outputs: > {code} > ExpressionSet(Seq( > IsNotNull(resolveColumn(multiAlias.analyze, "x")), > IsNotNull(resolveColumn(multiAlias.analyze, "y")) > ) > {code} > The constraint {code}resolveColumn(multiAlias.analyze, "x") === > resolveColumn(multiAlias.analyze, "y") + 10){code} is missing. -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org