You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Yin Huai (JIRA)" <ji...@apache.org> on 2015/05/13 23:18:01 UTC
[jira] [Created] (SPARK-7616) Overwriting a partitioned parquet
table corrupt data
Yin Huai created SPARK-7616:
-------------------------------
Summary: Overwriting a partitioned parquet table corrupt data
Key: SPARK-7616
URL: https://issues.apache.org/jira/browse/SPARK-7616
Project: Spark
Issue Type: Bug
Components: SQL
Affects Versions: 1.4.0
Reporter: Yin Huai
Assignee: Cheng Lian
Priority: Blocker
{code}
import sqlContext._
import sqlContext.implicits._
import org.apache.spark.sql.SaveMode
val df = createDataFrame(Seq((1,2),(2,3),(3,4))).toDF("a", "b")
df.saveAsTable("test2", "parquet", SaveMode.Overwrite, Map.empty[String, String], Seq("b"))
table("test2").show
// You will see
// +-+-+
// |a|b|
// +-+-+
// |1|2|
// |2|3|
// |3|4|
// +-+-+
df.saveAsTable("test2", "parquet", SaveMode.Overwrite, Map.empty[String, String], Seq("a"))
table("test2").show
// You will see
// +-+-+
// |b|a|
// +-+-+
// |1|2|
// |2|3|
// |3|4|
// +-+-+
{code}
--
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