List of utility methods to do SQL ResultSet Read
List | readResults(ResultSet resultSet) read Results String[] columns = getColumns(resultSet); List<Map<String, Object>> results = new ArrayList<Map<String, Object>>(); while (resultSet.next()) { Map<String, Object> current = new LinkedHashMap<String, Object>(); for (int i = 0; i < columns.length; i++) { Object data = resultSet.getObject(columns[i]); if (data != null) { current.put(columns[i].toLowerCase(), resultSet.getObject(columns[i])); ... |
T | wasNull(ResultSet rs, T value) was Null return rs.wasNull() ? null : value;
|
T | wasNull(ResultSet rs, T value) Convenient way to check if a JDBC-originated record was null .
return rs.wasNull() ? null : value;
|
T | wasNull(ResultSet rs, T value) Convenient way to check if a JDBC-originated record was null .
return (value == null || rs.wasNull()) ? null : value;
|