SourabhBadhya commented on code in PR #4672:
URL: https://github.com/apache/hive/pull/4672#discussion_r1335904688
##########
ql/src/java/org/apache/hadoop/hive/ql/ddl/table/misc/truncate/TruncateTableAnalyzer.java:
##########
@@ -80,8 +86,25 @@ public void analyzeInternal(ASTNode root) throws
SemanticException {
checkTruncateEligibility(root, tableNode, tableNameString, table);
Map<String, String> partitionSpec = getPartSpec((ASTNode)
tableNode.getChild(1));
+
addTruncateTableOutputs(tableNode, table, partitionSpec);
+ if (table.getStorageHandler() != null &&
!table.getStorageHandler().shouldTruncate(table, partitionSpec)) {
Review Comment:
@deniskuzZ -
https://github.com/apache/hive/pull/4672/files#diff-6dddcdd0457f600011f14e64854f8c030f9d1ae509b1e9fc63061dd0c8596a54R94
##########
ql/src/java/org/apache/hadoop/hive/ql/ddl/table/misc/truncate/TruncateTableAnalyzer.java:
##########
@@ -80,8 +86,25 @@ public void analyzeInternal(ASTNode root) throws
SemanticException {
checkTruncateEligibility(root, tableNode, tableNameString, table);
Map<String, String> partitionSpec = getPartSpec((ASTNode)
tableNode.getChild(1));
+
addTruncateTableOutputs(tableNode, table, partitionSpec);
+ if (table.getStorageHandler() != null &&
!table.getStorageHandler().shouldTruncate(table, partitionSpec)) {
Review Comment:
@deniskuzZ -
https://github.com/apache/hive/pull/4672/files#diff-6dddcdd0457f600011f14e64854f8c030f9d1ae509b1e9fc63061dd0c8596a54R94
It shows canTruncate to me.
--
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]