code: public static void closeResultSet(ResultSet rs) {
          try {
              if (rs != null && !rs.isClosed()) {
                  rs.close();
              }
          } catch (SQLException ex) {
              LOGGER.trace(rs.toString(), ex);
          }
      }
docs: Closes the result set capturing and ignoring any SQLExceptions that
  occur.
  
  @param rs a ResultSet to close