Map<String, Object> maxIdMap =
				result.stream()
			        .filter(m -> m.get("id") != null)
			        .max(Comparator.comparingInt(m ->
			                  Integer.parseInt(m.get("id").toString())))
			        .orElse(null);

 

+ Recent posts