spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Wenchen Fan (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (SPARK-15549) Disable bucketing when the output doesn't contain all bucketing columns
Date Sat, 28 May 2016 17:21:12 GMT

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

Wenchen Fan updated SPARK-15549:
--------------------------------
    Assignee: Yadong Qi

> Disable bucketing when the output doesn't contain all bucketing columns
> -----------------------------------------------------------------------
>
>                 Key: SPARK-15549
>                 URL: https://issues.apache.org/jira/browse/SPARK-15549
>             Project: Spark
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 2.0.0
>            Reporter: Yadong Qi
>            Assignee: Yadong Qi
>             Fix For: 2.0.0
>
>
> I create a bucketed table test(i int, j int, k int) with bucket column i, 
> {code:java}
> case class Data(i: Int, j: Int, k: Int)
> sc.makeRDD(Array((1, 2, 3))).map(x => Data(x._1, x._2, x._3)).toDF.write.bucketBy(2,
"i").saveAsTable("test")
> {code}
> and I run the following SQL:
> {code:sql}
> SELECT j FROM test;
> Error in query: bucket column i not found in existing columns (j);
> SELECT j, MAX(k) FROM test GROUP BY j;
> Error in query: bucket column i not found in existing columns (j, k);
> {code}
> I think the bucket column only need to be found in the output of relation. So the 2 sqls
bellow should be executed right.



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


Mime
View raw message