huaxingao commented on code in PR #14831:
URL: https://github.com/apache/iceberg/pull/14831#discussion_r2615185182


##########
hive-metastore/src/main/java/org/apache/iceberg/hive/HiveViewOperations.java:
##########
@@ -146,6 +144,9 @@ public void doCommit(ViewMetadata base, ViewMetadata 
metadata) {
               viewName);
         }
 
+        String sqlQuery = sqlFor(metadata);
+        tbl.setViewExpandedText(sqlQuery);
+        tbl.setViewOriginalText(sqlQuery);

Review Comment:
   Shall we add null check? 
   ```
     if (sqlQuery != null) {
       tbl.setViewExpandedText(sqlQuery);
       tbl.setViewOriginalText(sqlQuery);
     }
   ```



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