jcamachor commented on a change in pull request #812: Hive 22324
URL: https://github.com/apache/hive/pull/812#discussion_r337286757
 
 

 ##########
 File path: 
ql/src/java/org/apache/hadoop/hive/ql/optimizer/calcite/rules/jdbc/HiveJdbcImplementor.java
 ##########
 @@ -109,7 +109,7 @@ public HiveJdbcImplementor(SqlDialect dialect, 
JavaTypeFactory typeFactory) {
     SqlNode sqlCondition = null;
     SqlLiteral condType = JoinConditionType.ON.symbol(POS);
     JoinType joinType = joinType(e.getJoinType());
-    if (e.getJoinType() == JoinRelType.INNER && 
e.getCondition().isAlwaysTrue()) {
+    if ((e.getJoinType() == JoinRelType.INNER || e.isSemiJoin()) && 
e.getCondition().isAlwaysTrue()) {
 
 Review comment:
   Do we have any test that triggers this logic? Is this actually correct or 
would it result in multiplying left input records? Logic seems to be slightly 
different in method in `RelToSqlConverter` in upstream Calcite.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org
For additional commands, e-mail: gitbox-h...@hive.apache.org

Reply via email to