如何从结果集(单独)从对象获取Key& value

时间:2017-12-19 09:34:36

标签: rest spring-boot plsql

SimpleJdbcCall simpleJdbcCall = new SimpleJdbcCall(jdbcTemplate);
simpleJdbcCall.withProcedureName("getMultipleResultsetProc");
HashMap<String, Object> paramMap = new HashMap<>();
paramMap.put("llId", userId);

Map<String, Object> resultsetMap = simpleJdbcCall.execute(paramMap);

Map<String, Object> results = new HashMap<>();

Object result1 = resultsetMap.get("#result-set-1"));
Object result2 = resultsetMap.get("#result-set-2"));

System.out.println("Resultset-1-->" + result1);
System.out.println("Resultset-2-->" + result2);

在上面的代码中给出了多个Resultsets,在每个Resultset中都有键值对

"result-set-1":[{ "key1":"value1","key2":"value2"}] 

我想从result-set-1(单独地)获得Key&amp;值

0 个答案:

没有答案