You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Fengdong Yu (JIRA)" <ji...@apache.org> on 2015/12/09 06:21:11 UTC

[jira] [Created] (SPARK-12233) Cannot specify a data frame column during join

Fengdong Yu created SPARK-12233:
-----------------------------------

             Summary: Cannot specify a data frame column during join
                 Key: SPARK-12233
                 URL: https://issues.apache.org/jira/browse/SPARK-12233
             Project: Spark
          Issue Type: Bug
          Components: SQL
    Affects Versions: 1.5.2
            Reporter: Fengdong Yu
            Priority: Minor


Background:

two tables: 
tableA(id string, name string, gender string)
tableB(id string, name string)

{code}
val df1 = sqlContext.sql(select * from tableA)
val df2 = sqlContext.sql(select * from tableB)

//Wrong
df1.join(df2, Seq("id", "name").select(df2("id"), df2("name"), df1("gender"))

//Correct
df1.join(df2, Seq("id", "name").select("id", "name", "gender")

{code}

========
Cannot specify column of data frame for 'gender'




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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