Yin Huai created SPARK-6016:
-------------------------------

             Summary: Cannot read the parquet table after overwriting the 
existing table when spark.sql.parquet.cacheMetadata=true
                 Key: SPARK-6016
                 URL: https://issues.apache.org/jira/browse/SPARK-6016
             Project: Spark
          Issue Type: Bug
          Components: SQL
            Reporter: Yin Huai
            Priority: Blocker


saveAsTable is fine and seems we have successfully deleted the old data and 
written the new data. However, when reading the newly created table, an error 
will be thrown.
{code}
Error in SQL statement: java.lang.RuntimeException: java.lang.RuntimeException: 
could not merge metadata: key org.apache.spark.sql.parquet.row.metadata has 
conflicting values: 
at parquet.hadoop.api.InitContext.getMergedKeyValueMetaData(InitContext.java:67)
        at parquet.hadoop.api.ReadSupport.init(ReadSupport.java:84)
        at 
org.apache.spark.sql.parquet.FilteringParquetRowInputFormat.getSplits(ParquetTableOperations.scala:469)
        at 
parquet.hadoop.ParquetInputFormat.getSplits(ParquetInputFormat.java:245)
        at 
org.apache.spark.sql.parquet.ParquetRelation2$$anon$1.getPartitions(newParquet.scala:461)
        ...
{code}

If I set spark.sql.parquet.cacheMetadata to false, it's fine to query the data.




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

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to