public static void dump(ResultSet rs) throws SQLException {
  ResultSetMetaData md=rs.getMetaData();
  for (int i=0; i < md.getColumnCount(); i++) {
    int index=i + 1;
    String info=md.getColumnLabel(index);
    String name=md.getColumnName(index);
    if (info == null)     info=name;
 else     if (name != null && !name.equals(info))     info+=" (" + name + ")";
    info+=" = " + rs.getString(index);
    info+=" [" + md.getColumnTypeName(index) + "("+ md.getPrecision(index);
    if (md.getScale(index) != 0)     info+="," + md.getScale(index);
    info+=")]";
    log.fine(info);
  }
}

public static void dump ( ResultSet rs ) throws SQLException { ResultSetMetaData md = rs . getMetaData ( ) ; for ( int i = 0 ; i < md . getColumnCount ( ) ; i ++ ) { int index = i + 1 ; String info = md . getColumnLabel ( index ) ; String name = md . getColumnName ( index ) ; if ( info == null ) info = name ; else if ( name != null && ! name . equals ( info ) ) info += " (" + name + ")" ; info += " = " + rs . getString ( index ) ; info += " [" + md . getColumnTypeName ( index ) + "(" + md . getPrecision ( index ) ; if ( md . getScale ( index ) != 0 ) info += "," + md . getScale ( index ) ; info += ")]" ; log . fine ( info ) ; } }
dump the current row of a result set
