[
https://issues.apache.org/jira/browse/SPARK-15903?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Hyukjin Kwon updated SPARK-15903:
---------------------------------
Labels: bulk-closed (was: )
> Support AllColumn expression in UDF functions
> ---------------------------------------------
>
> Key: SPARK-15903
> URL: https://issues.apache.org/jira/browse/SPARK-15903
> Project: Spark
> Issue Type: Improvement
> Components: SQL
> Affects Versions: 1.6.1
> Reporter: Lijie Xu
> Priority: Minor
> Labels: bulk-closed
>
> Sometimes, we want to put all the columns in the UDF functions such as
> "concat()". We would like to use simple $"*" instead of listing each column
> as follows.
> val df = sc.makeRDD(Array((1, "A"), (2, "B"), (3, "C"))).toDF("Id", "Name")
> val result = df.select($"*", concat($"\*").as("UDF")) // failed
> val result = df.select($"*", concat($"Id", $"Name").as("UDF")) // passed
> result.show()
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]