maheshk114 commented on code in PR #4636:
URL: https://github.com/apache/hive/pull/4636#discussion_r1342604471
##########
ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java:
##########
@@ -3603,7 +3603,29 @@ private Operator genFilterPlan(ASTNode searchCond, QB
qb, Operator input,
* push filters only for this QBJoinTree. Child QBJoinTrees have
already been handled.
*/
pushJoinFilters(qb, joinTree, aliasToOpInfo, false);
- input = genJoinOperator(qbSQ, joinTree, aliasToOpInfo, input);
+
+ /*
+ * Note that: in case of multi dest queries, with even one containing
a notIn operator, the code is not changed yet.
+ * That needs to be worked on as a separate bug
+ * e.g.
+ * from t3 b
+ * INSERT OVERWRITE TABLE t4
+ * select *
+ * where b.age not in
+ * (select a.age
+ * from t3 a
+ * )
+ * order by age
+ * INSERT OVERWRITE TABLE t5
+ * select *
+ * where b.age in
+ * (select c.age
+ * from t3 c
+ * );
+ */
+ boolean notInCheck = (subQuery.getNotInCheck() != null &&
!qb.isMultiDestQuery() );
Review Comment:
nit: remove extra space.
##########
ql/src/test/results/clientpositive/llap/special_character_in_tabnames_quotes_1.q.out:
##########
@@ -3071,23 +3086,49 @@ STAGE PLANS:
Tez
#### A masked pattern was here ####
Edges:
- Reducer 2 <- Map 1 (CUSTOM_SIMPLE_EDGE), Reducer 6 (CUSTOM_SIMPLE_EDGE)
+ Reducer 2 <- Map 1 (CUSTOM_SIMPLE_EDGE), Reducer 7 (CUSTOM_SIMPLE_EDGE)
Reducer 3 <- Reducer 2 (SIMPLE_EDGE), Reducer 5 (SIMPLE_EDGE)
Reducer 4 <- Reducer 3 (SIMPLE_EDGE)
Reducer 5 <- Map 1 (SIMPLE_EDGE)
- Reducer 6 <- Reducer 5 (CUSTOM_SIMPLE_EDGE)
+ Reducer 6 <- Map 1 (SIMPLE_EDGE)
+ Reducer 7 <- Reducer 6 (CUSTOM_SIMPLE_EDGE)
#### A masked pattern was here ####
Vertices:
Map 1
Map Operator Tree:
TableScan
alias: b
+ filterExpr: ((p_size is not null and p_mfgr is not null) or
((p_size < 10) and p_mfgr is not null) or (p_size < 10)) (type: boolean)
Statistics: Num rows: 26 Data size: 5798 Basic stats:
COMPLETE Column stats: COMPLETE
- Reduce Output Operator
- null sort order:
- sort order:
+ Filter Operator
+ predicate: (p_size is not null and p_mfgr is not null)
(type: boolean)
Statistics: Num rows: 26 Data size: 5798 Basic stats:
COMPLETE Column stats: COMPLETE
- value expressions: p_name (type: string), p_mfgr (type:
string), p_size (type: int)
+ Reduce Output Operator
+ null sort order:
+ sort order:
+ Statistics: Num rows: 26 Data size: 5798 Basic stats:
COMPLETE Column stats: COMPLETE
+ value expressions: p_name (type: string), p_mfgr (type:
string), p_size (type: int)
+ Filter Operator
+ predicate: ((p_size < 10) and p_mfgr is not null) (type:
boolean)
+ Statistics: Num rows: 5 Data size: 510 Basic stats:
COMPLETE Column stats: COMPLETE
+ Select Operator
+ expressions: p_mfgr (type: string), p_size (type: int)
+ outputColumnNames: _col0, _col1
+ Statistics: Num rows: 5 Data size: 510 Basic stats:
COMPLETE Column stats: COMPLETE
+ Group By Operator
+ aggregations: min(_col1)
+ keys: _col0 (type: string)
+ minReductionHashAggr: 0.4
+ mode: hash
+ outputColumnNames: _col0, _col1
Review Comment:
can you please check why the extra group by operator is added ?
##########
ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java:
##########
@@ -3603,7 +3603,29 @@ private Operator genFilterPlan(ASTNode searchCond, QB
qb, Operator input,
* push filters only for this QBJoinTree. Child QBJoinTrees have
already been handled.
*/
pushJoinFilters(qb, joinTree, aliasToOpInfo, false);
- input = genJoinOperator(qbSQ, joinTree, aliasToOpInfo, input);
+
+ /*
+ * Note that: in case of multi dest queries, with even one containing
a notIn operator, the code is not changed yet.
+ * That needs to be worked on as a separate bug
Review Comment:
please create a Jira and add the link here.
--
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]