Package net.sf.jsqlparser.expression.operators.relational

Examples of net.sf.jsqlparser.expression.operators.relational.MinorThan


        _columnOrderdate = new Column();
        _columnOrderdate.setTable(table);
        _columnOrderdate.setColumnName("ORDERDATE");

        MinorThan mt = new MinorThan();
        mt.setLeftExpression(_columnOrderdate);
        mt.setRightExpression(new DateValue(" 1995-01-01 "));
       
        String path = "../test/squall/schemas/tpch.txt";
        double scallingFactor = 1;
        _selEstimator = new SelingerSelectivityEstimator("TEST", new Schema(path, scallingFactor), new TableAliasName(tableList, "SelingerTest"));
    }
View Full Code Here


   
    @Test
    public void testEstimate_MinorThan() {
        LOG.info("test estimate(MinorThan):");
        MinorThan mt = new MinorThan();
        mt.setLeftExpression(_columnOrderdate);
        mt.setRightExpression(new DateValue("d" + "1995-01-01" + "d"));
        assertEquals("0.45571725571725574", String.valueOf(_selEstimator.estimate(mt)));
    }
View Full Code Here

  public double estimate(GreaterThan gt) {
    final EqualsTo equals = new EqualsTo();
    equals.setLeftExpression(gt.getLeftExpression());
    equals.setRightExpression(gt.getRightExpression());

    final MinorThan minorThan = new MinorThan();
    minorThan.setLeftExpression(gt.getLeftExpression());
    minorThan.setRightExpression(gt.getRightExpression());

    return 1 - estimate(equals) - estimate(minorThan);
  }
View Full Code Here

    return 1 - estimate(equals) - estimate(minorThan);
  }

  public double estimate(GreaterThanEquals gt) {
    final MinorThan minorThan = new MinorThan();
    minorThan.setLeftExpression(gt.getLeftExpression());
    minorThan.setRightExpression(gt.getRightExpression());

    return 1 - estimate(minorThan);
  }
View Full Code Here

  public double estimate(MinorThanEquals mte) {
    final EqualsTo equals = new EqualsTo();
    equals.setLeftExpression(mte.getLeftExpression());
    equals.setRightExpression(mte.getRightExpression());

    final MinorThan minorThan = new MinorThan();
    minorThan.setLeftExpression(mte.getLeftExpression());
    minorThan.setRightExpression(mte.getRightExpression());

    return estimate(minorThan) + estimate(equals);
  }
View Full Code Here

      jj_consume_token(84);
              result = new GreaterThan();
      break;
    case 85:
      jj_consume_token(85);
                result = new MinorThan();
      break;
    case 77:
      jj_consume_token(77);
                result = new EqualsTo();
      break;
View Full Code Here

        else if (exp instanceof GreaterThanEquals)
            qualified = new GreaterThanEquals();
        else if (exp instanceof LikeExpression)
            qualified = new LikeExpression();
        else if (exp instanceof MinorThan)
            qualified = new MinorThan();
        else if (exp instanceof MinorThanEquals)
            qualified = new MinorThanEquals();
        else if (exp instanceof NotEqualsTo)
            qualified = new NotEqualsTo();
        else
View Full Code Here

TOP

Related Classes of net.sf.jsqlparser.expression.operators.relational.MinorThan

Copyright © 2018 www.massapicom. 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.