Examples of SemiJoinRel


Examples of org.eigenbase.rel.rules.SemiJoinRel

          "EnumerableSemiJoinRule");
    }

    @Override
    public RelNode convert(RelNode rel) {
      final SemiJoinRel semiJoin = (SemiJoinRel) rel;
      List<RelNode> newInputs = new ArrayList<RelNode>();
      for (RelNode input : semiJoin.getInputs()) {
        if (!(input.getConvention() instanceof EnumerableConvention)) {
          input =
              convert(input,
                  input.getTraitSet().replace(EnumerableConvention.INSTANCE));
        }
        newInputs.add(input);
      }
      try {
        return new EnumerableSemiJoinRel(
            semiJoin.getCluster(),
            semiJoin.getTraitSet().replace(EnumerableConvention.INSTANCE),
            newInputs.get(0),
            newInputs.get(1),
            semiJoin.getCondition(),
            semiJoin.leftKeys,
            semiJoin.rightKeys);
      } catch (InvalidRelException e) {
        LOGGER.fine(e.toString());
        return null;
View Full Code Here

Examples of org.eigenbase.rel.rules.SemiJoinRel

        final List<Integer> rightKeys = new ArrayList<Integer>();
        optiqJoinCond = HiveOptiqUtil.projectNonColumnEquiConditions(
            HiveProjectRel.DEFAULT_PROJECT_FACTORY, inputRels, leftJoinKeys, rightJoinKeys, 0,
            leftKeys, rightKeys);

        joinRel = new SemiJoinRel(cluster, cluster.traitSetOf(HiveRel.CONVENTION),
            inputRels[0], inputRels[1], optiqJoinCond, ImmutableIntList.copyOf(leftKeys),
            ImmutableIntList.copyOf(rightKeys));
      } else {
        joinRel = HiveJoinRel.getJoin(cluster, leftRel, rightRel, optiqJoinCond, optiqJoinType,
            leftSemiJoin);
View Full Code Here

Examples of org.eigenbase.rel.rules.SemiJoinRel

   */
  private static class SemiJoinFactoryImpl implements SemiJoinFactory {
    public RelNode createSemiJoin(RelNode left, RelNode right,
        RexNode condition) {
      final JoinInfo joinInfo = JoinInfo.of(left, right, condition);
      return new SemiJoinRel(left.getCluster(), left.getTraitSet(), left, right,
        condition, joinInfo.leftKeys, joinInfo.rightKeys);
    }
View Full Code Here

Examples of org.eigenbase.rel.rules.SemiJoinRel

          "EnumerableSemiJoinRule");
    }

    @Override
    public RelNode convert(RelNode rel) {
      final SemiJoinRel semiJoin = (SemiJoinRel) rel;
      List<RelNode> newInputs = new ArrayList<RelNode>();
      for (RelNode input : semiJoin.getInputs()) {
        if (!(input.getConvention() instanceof EnumerableConvention)) {
          input =
              convert(input,
                  input.getTraitSet().replace(EnumerableConvention.INSTANCE));
        }
        newInputs.add(input);
      }
      try {
        return new EnumerableSemiJoinRel(
            semiJoin.getCluster(),
            semiJoin.getTraitSet().replace(EnumerableConvention.INSTANCE),
            newInputs.get(0),
            newInputs.get(1),
            semiJoin.getCondition(),
            semiJoin.leftKeys,
            semiJoin.rightKeys);
      } catch (InvalidRelException e) {
        LOGGER.fine(e.toString());
        return null;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.