class TStringUtil extends StringUtils {

    public static String removeBetween(String sql, String start, String end) {
        if (sql == null) {
            return null;
        }

        if (start == null || end == null) {
            return sql;
        }

        int index0 = sql.indexOf(start);
        if (index0 == -1) {
            return sql;
        }
        int index1 = sql.indexOf(end, index0);
        if (index1 == -1) {
            return sql;
        }
        StringBuilder sb = new StringBuilder();
        sb.append(sql.substring(0, index0));
        sb.append(" ");
        sb.append(sql.substring(index1 + end.length()));
        return sb.toString();
    }

}