List rs1 = this.jdbcTemplate.queryForList("select count(*) as counter from (" + sqlString + ")",obj);
if (rs1 != null && !rs1.isEmpty() && rs1.size() > 0) {
ListOrderedMap map = (ListOrderedMap) rs1.iterator().next();
pagenator.setCount(((BigDecimal) map.getValue(0)).intValue());
} else {
pagenator.setCount(0);}
if (rs1 != null && !rs1.isEmpty() && rs1.size() > 0) {
ListOrderedMap map = (ListOrderedMap) rs1.iterator().next();
pagenator.setCount(((BigDecimal) map.getValue(0)).intValue());
} else {
pagenator.setCount(0);}