flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fhueske <...@git.apache.org>
Subject [GitHub] flink pull request #4842: [FLINK-7853] [table] Reject table function outer j...
Date Tue, 17 Oct 2017 21:41:07 GMT
Github user fhueske commented on a diff in the pull request:

    https://github.com/apache/flink/pull/4842#discussion_r145257154
  
    --- Diff: flink-libraries/flink-table/src/main/scala/org/apache/flink/table/plan/logical/operators.scala
---
    @@ -476,20 +481,30 @@ case class Join(
             } else {
               nonEquiJoinPredicateFound = true
             }
    +      // The boolean literal should be valid condition type.
    +      case x: Literal if x.resultType == Types.BOOLEAN =>
           case x => failValidation(
             s"Unsupported condition type: ${x.getClass.getSimpleName}. Condition: $x")
         }
     
         validateConditions(expression, isAndBranch = true)
    -    if (!equiJoinPredicateFound) {
    -      failValidation(
    -        s"Invalid join condition: $expression. At least one equi-join predicate is "
+
    -          s"required.")
    -    }
    -    if (joinType != JoinType.INNER && (nonEquiJoinPredicateFound || localPredicateFound))
{
    -      failValidation(
    -        s"Invalid join condition: $expression. Non-equality join predicates or local"
+
    -          s" predicates are not supported in outer joins.")
    +
    +    // Due to CALCITE-2004, we cannot accept join predicates except literal true for
TableFunction
    +    // left outer join.
    +    if (correlated && right.isInstanceOf[LogicalTableFunctionCall] &&
joinType != JoinType.INNER ) {
    +      if (!alwaysTrue) failValidation("TableFunction left outer join predicates can only
be " +
    --- End diff --
    
    `predicates` -> `predicate`


---

Mime
View raw message