Help Center/ MapReduce Service/ Troubleshooting/ Using Spark/ Why Are Table Statistics Empty Before Data Insertion for New Hudi or Hive Tables Created Using Spark SQL?
Updated on 2026-10-21 GMT+08:00
Why Are Table Statistics Empty Before Data Insertion for New Hudi or Hive Tables Created Using Spark SQL?
Symptom
When Spark SQL is used to create Hudi or Hive tables, the table statistics are empty before data is inserted.
Procedure
You can use either of the following methods to collect the statistics:
- Run the analyze command to trigger statistics collection. If no data is inserted, run the desc formatted table_name command to check whether the value of totalsize is 0 after the analyze command is executed.
- Set spark.sql.statistics.size.autoUpdate.enabled to true and insert data. Statistics collection will be triggered in the background.
Parent topic: Using Spark
What is your overall rating for this page?
0
1
2
3
4
5
6
7
8
9
10
Very dissatisfiedVery satisfied
Thank you very much for your feedback. We will continue working to improve the documentation.
The system is busy. Please try again later.