zabetak commented on code in PR #5022:
URL: https://github.com/apache/hive/pull/5022#discussion_r1579274060


##########
ql/src/java/org/apache/hadoop/hive/ql/parse/LoadSemanticAnalyzer.java:
##########
@@ -244,6 +245,7 @@ public void analyzeInternal(ASTNode ast) throws 
SemanticException {
     } else {
       analyzeLoad(ast);
     }
+    queryState.setCommandType(HiveOperation.LOAD);

Review Comment:
   As far as I see we obtain a `LoadSemanticAnalyzer` from 
https://github.com/apache/hive/blob/e980c7a5e6ba3adec473a30e3ea0a539a5eae257/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactory.java#L75
   and few lines before we set the command type using 
https://github.com/apache/hive/blob/e980c7a5e6ba3adec473a30e3ea0a539a5eae257/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactory.java#L62
   so I suppose initially the type is set correctly to `LOAD`.
   
   Why do need to reset the type here? Who is changing it to `QUERY` and why? 
Was it intentional/necessary?



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