vineetgarg02 commented on a change in pull request #809: HIVE-22274: upgrade
Calcite to 1.21
URL: https://github.com/apache/hive/pull/809#discussion_r334609909
##########
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:
Existing logic looks wrong. Even for SEMI JOIN `JoinType.COMMA` with
condition `NONE` is created (in case condition is always true).
@jcamachor Are there JDBC tests where I can test this logic for SEMI JOIN
type?
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]