SourabhBadhya commented on code in PR #4440:
URL: https://github.com/apache/hive/pull/4440#discussion_r1247389338


##########
ql/src/java/org/apache/hadoop/hive/ql/stats/ColStatsProcessor.java:
##########
@@ -218,10 +221,15 @@ public int persistColumnStats(Hive db, Table tbl) throws 
HiveException, MetaExce
       }
 
       start = System. currentTimeMillis();
+      boolean success = false;
       if (tbl != null && tbl.isNonNative() && 
tbl.getStorageHandler().canSetColStatistics(tbl)) {
-        tbl.getStorageHandler().setColStatistics(tbl, colStats);
+        success = tbl.getStorageHandler().setColStatistics(tbl, colStats);
+      }
+      success |= db.setPartitionColumnStatistics(request);
+      if (!(tbl.isMaterializedView() || tbl.isView() || tbl.isTemporary())) {
+        TableName tableName = new TableName(tbl.getCatalogName(), 
tbl.getDbName(), tbl.getTableName());
+        setOrRemoveColumnStatsAccurateProperty(db, tableName, 
colStatDesc.getColName(), success);

Review Comment:
   @kasakrisz Yes you are right, this is updating for partition level stats and 
that was why there were so many q.out changes. I have added a clause to update 
this field only when there are table level updates. Done.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org
For additional commands, e-mail: gitbox-h...@hive.apache.org

Reply via email to