zhangbutao commented on code in PR #5959:
URL: https://github.com/apache/hive/pull/5959#discussion_r2200224390


##########
iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergMetaHook.java:
##########
@@ -815,8 +815,8 @@ private void assertFileFormat(String format) {
   }
 
   private void 
setCommonHmsTablePropertiesForIceberg(org.apache.hadoop.hive.metastore.api.Table
 hmsTable) {
-    // If the table is not managed by Hive catalog then the location should be 
set
-    if (!Catalogs.hiveCatalog(conf, catalogProperties)) {
+    // If the table is not managed by Hive or Hadoop catalog, then the 
location should be set
+    if (!Catalogs.hiveCatalog(conf, catalogProperties) && 
!Catalogs.hadoopCatalog(conf, catalogProperties)) {

Review Comment:
   I don't get this change. I still can create Hadoop catalog tables without 
setting the location.
   ```
   set iceberg.catalog.ice01.type=hadoop;
   set iceberg.catalog.ice01.warehouse=hdfs://127.0.0.1:8020/tmp;
   
   CREATE EXTERNAL TABLE orders (orderid INT, quantity INT, itemid INT, tradets 
TIMESTAMP) PARTITIONED BY (p1 STRING, p2 STRING) STORED BY ICEBERG STORED AS 
ORC;
   ```



-- 
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