nayan_wylde
Esteemed Contributor II

It is recommended to run ANALYZE TABLE table_name COMPUTE DELTA STATISTICS after the data has been loaded into the Delta table, rather than while the data is being loaded.

  1. Data consistency: Running the command after the data has been loaded ensures that the statistics are collected on a consistent view of the data, which is essential for accurate query optimization.
  2. Statistics accuracy: If the command is run while the data is being loaded, the statistics may not reflect the final state of the data, which can lead to suboptimal query plans.
  3. Performance: Running the command after the data has been loaded allows the statistics collection process to run without interfering with the data loading process, which can improve overall performance.