ayushtkn commented on code in PR #4453:
URL: https://github.com/apache/hive/pull/4453#discussion_r1245349132


##########
iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java:
##########
@@ -362,16 +362,30 @@ public StorageFormatDescriptor 
getStorageFormatDescriptor(org.apache.hadoop.hive
     return null;
   }
 
-  public boolean supportsAppendData(org.apache.hadoop.hive.metastore.api.Table 
table) throws SemanticException {
+  public boolean supportsAppendData(org.apache.hadoop.hive.metastore.api.Table 
table, boolean withPartClause)
+      throws SemanticException {
     Table icebergTbl = IcebergTableUtil.getTable(conf, table);
-    return icebergTbl.spec().isUnpartitioned();
+
+    // If it is a table which has undergone partition evolution, return false;
+    if (icebergTbl.currentSnapshot() != null) {
+      if 
(icebergTbl.currentSnapshot().allManifests(icebergTbl.io()).parallelStream().map(ManifestFile::partitionSpecId)

Review Comment:
   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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to