private String makeFormatString(String colName, String operator,
      Object[] conditionArr, boolean isAnd) throws SQLException, Exception {
    String condFormatStr = ""; // Holds the format string for this condition
    if (conditionArr.length == 0) {
      throw new SQLException("conditionArr cannot have length 0");
    }
    if (isOperator(operator)) {
      // Setup the format string for this condition
      if (whereStrArr.size() > 0) {
        if (isAnd) {
          condFormatStr += "AND ";
        } else {
          condFormatStr += "OR ";
        }
      }
      // Setup operator with ?'s based on which operator is being used
      condFormatStr += colName + " " + operator + " ";
      if (operator.equalsIgnoreCase("BETWEEN")) {
        if (conditionArr.length != 2) {
          throw new SQLException("BETWEEN needs 2 args");
        }
        condFormatStr += "? AND ?";
      } else if (operator.equalsIgnoreCase("IN")) {
        condFormatStr += "(";
        if (conditionArr.length != 0) // first one = no preceding comma
          condFormatStr += "?";
        for (int i = 1; i < conditionArr.length; i++) {
          condFormatStr += ",?";
        }
        condFormatStr += ")";
      } else {
        condFormatStr += "?";
      }
      return condFormatStr;
    } else {
      throw new Exception(String.format("%s is not an operator", operator));
    }
  }