pvary commented on code in PR #3131:
URL: https://github.com/apache/hive/pull/3131#discussion_r843564071


##########
ql/src/java/org/apache/hadoop/hive/ql/parse/UpdateDeleteSemanticAnalyzer.java:
##########
@@ -97,12 +100,22 @@ private void reparseAndSuperAnalyze(ASTNode tree) throws 
SemanticException {
     Table mTable = getTargetTable(tabName);
     validateTargetTable(mTable);
 
+    // save the operation type into the query state
+    SessionStateUtil.addResource(conf, 
Context.Operation.class.getSimpleName(), operation.name());
+
     StringBuilder rewrittenQueryStr = new StringBuilder();
     rewrittenQueryStr.append("insert into table ");
     rewrittenQueryStr.append(getFullTableNameForSQL(tabName));
     addPartitionColsToInsert(mTable.getPartCols(), rewrittenQueryStr);
 
-    rewrittenQueryStr.append(" select ROW__ID");
+    boolean nonNativeAcid = mTable.getStorageHandler() != null && 
mTable.getStorageHandler().supportsAcidOperations();

Review Comment:
   Maybe an util for this?
   I have seen this several times



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