deniskuzZ commented on code in PR #4026:
URL: https://github.com/apache/hive/pull/4026#discussion_r1102465805
##########
ql/src/java/org/apache/hadoop/hive/ql/parse/UpdateDeleteSemanticAnalyzer.java:
##########
@@ -145,11 +162,21 @@ private void reparseAndSuperAnalyze(ASTNode tree, Table
mTable, ASTNode tabNameN
where = (ASTNode)children.get(whereIndex);
assert where.getToken().getType() == HiveParser.TOK_WHERE :
"Expected where clause, but found " + where.getName();
- }
- // Add a sort by clause so that the row ids come out in the correct order
- appendSortBy(rewrittenQueryStr, columnAppender.getSortKeys());
+ if (shouldOverwrite) {
+ assert where.getChildCount() < 2 : "Overwrite mode not supported with
more than 1 children in where clause.";
+ for (int i = 0; i < where.getChildCount(); i++) {
+ ASTNode node = new ASTNode(new CommonToken(HiveParser.KW_NOT, "!"));
Review Comment:
would it work with `where a=NULL` ?
--
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]