[jira] [Updated] (SPARK-16853) Analysis error for DataSet typed selection

2016-12-08 Thread Dongjoon Hyun (JIRA)

 [ 
https://issues.apache.org/jira/browse/SPARK-16853?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Dongjoon Hyun updated SPARK-16853:
--
Component/s: SQL

> Analysis error for DataSet typed selection
> --
>
> Key: SPARK-16853
> URL: https://issues.apache.org/jira/browse/SPARK-16853
> Project: Spark
>  Issue Type: Bug
>  Components: SQL
>Reporter: Sean Zhong
>Assignee: Sean Zhong
> Fix For: 2.1.0
>
>
> For DataSet typed selection
> {code}
> def select[U1: Encoder](c1: TypedColumn[T, U1]): Dataset[U1]
> {code}
> If U1 contains sub-fields, then it reports AnalysisException 
> Reproducer:
> {code}
> scala> case class A(a: Int, b: Int)
> scala> Seq((0, A(1,2))).toDS.select($"_2".as[A])
> org.apache.spark.sql.AnalysisException: cannot resolve '`a`' given input 
> columns: [_2];
>   at 
> org.apache.spark.sql.catalyst.analysis.package$AnalysisErrorAt.failAnalysis(package.scala:42)
>   at 
> ...
> {code}



--
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



[jira] [Updated] (SPARK-16853) Analysis error for DataSet typed selection

2016-08-04 Thread Wenchen Fan (JIRA)

 [ 
https://issues.apache.org/jira/browse/SPARK-16853?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Wenchen Fan updated SPARK-16853:

Assignee: Sean Zhong

> Analysis error for DataSet typed selection
> --
>
> Key: SPARK-16853
> URL: https://issues.apache.org/jira/browse/SPARK-16853
> Project: Spark
>  Issue Type: Bug
>Reporter: Sean Zhong
>Assignee: Sean Zhong
>
> For DataSet typed selection
> {code}
> def select[U1: Encoder](c1: TypedColumn[T, U1]): Dataset[U1]
> {code}
> If U1 contains sub-fields, then it reports AnalysisException 
> Reproducer:
> {code}
> scala> case class A(a: Int, b: Int)
> scala> Seq((0, A(1,2))).toDS.select($"_2".as[A])
> org.apache.spark.sql.AnalysisException: cannot resolve '`a`' given input 
> columns: [_2];
>   at 
> org.apache.spark.sql.catalyst.analysis.package$AnalysisErrorAt.failAnalysis(package.scala:42)
>   at 
> ...
> {code}



--
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