log.info(sb.toString()); log.info("-------------------------------------------------------------------------------");
if (log != null) { log.info(sb.toString()); log.info("-------------------------------------------------------------------------------"); }
    private void readResult(String title, ResultSet rs, boolean print) throws SQLException    {        ResultSetMetaData md = rs.getMetaData();        int cols = md.getColumnCount();        if (print) {            log.info(title);            log.info("-------------------------------------------------------------------------------");            StringBuffer sb = new StringBuffer();            for (int i = 1; i <= cols; i++) {                if (i > 1)                    sb.append('\t');                sb.append(md.getColumnLabel(i));            }            log.info(sb.toString());            log.info("-------------------------------------------------------------------------------");        }        while (rs.next()) {            StringBuffer sb = new StringBuffer();            for (int i = 1; i <= cols; i++) {                String value = rs.getString(i);                                        if (i > 1)                    sb.append('\t');                sb.append(value);                                    }            log.info(sb);        }        rs.close();    }