final
List scopeList
=
new
ArrayList();
jdbcTemplate.query(sql, new RowCallbackHandler() {
public void processRow(ResultSet rs) throws SQLException {
Bmbh bm = new Bmbh();
bm.setDeptId(rs.getString( 1 ));
bm.setDeptName(rs.getString( 2 ));
scopeList.add(bm);
}
}
);
jdbcTemplate.query(sql, new RowCallbackHandler() {
public void processRow(ResultSet rs) throws SQLException {
Bmbh bm = new Bmbh();
bm.setDeptId(rs.getString( 1 ));
bm.setDeptName(rs.getString( 2 ));
scopeList.add(bm);
}
}
);