Skip to content

Commit

Permalink
[hotfix] [tableAPI] Throw helpful exception for unsupported outer joins.
Browse files Browse the repository at this point in the history
  • Loading branch information
fhueske committed May 23, 2016
1 parent 905ac6e commit 53949d1
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import org.apache.calcite.rel.convert.ConverterRule
import org.apache.calcite.rel.core.JoinRelType
import org.apache.calcite.rel.logical.LogicalJoin
import org.apache.flink.api.java.operators.join.JoinType
import org.apache.flink.api.table.TableException
import org.apache.flink.api.table.plan.nodes.dataset.{DataSetJoin, DataSetConvention}

import scala.collection.JavaConversions._
Expand All @@ -44,6 +45,9 @@ class DataSetJoinRule
val hasValidCondition = !joinInfo.pairs().isEmpty
// only inner joins are supported at the moment
val isInnerJoin = join.getJoinType.equals(JoinRelType.INNER)
if (!isInnerJoin) {
throw new TableException("OUTER JOIN is currently not supported.")
}

// check that condition is valid and inner join
hasValidCondition && isInnerJoin
Expand Down

0 comments on commit 53949d1

Please sign in to comment.