class BeamSqlSubstringExpression extends BeamSqlExpression {

  @Override
  public boolean accept() {
    if (operands.size() < 2 || operands.size() > 3) {
      return false;
    }

    if (!SqlTypeName.CHAR_TYPES.contains(opType(0)) || !SqlTypeName.INT_TYPES.contains(opType(1))) {
      return false;
    }

    if (operands.size() == 3 && !SqlTypeName.INT_TYPES.contains(opType(2))) {
      return false;
    }

    return true;
  }

  public  BeamSqlSubstringExpression(List<BeamSqlExpression> operands);

}