How to load data from JDBCTemplate.queryForMap() and it returns the Map Interface.How the maintained the query data internally in map.I trying to load but i go
JDBCTemplate.queryForMap()
To add to @BrianBeech's answer, this is even more trimmed down in java 8:
jdbcTemplate.query("select string1,string2 from table where x=1", (ResultSet rs) -> { HashMap results = new HashMap<>(); while (rs.next()) { results.put(rs.getString("string1"), rs.getString("string2")); } return results; });