This patch correctly increments consecutive calls to
PreparedStatement.setInt().
Change-Id: Ib07d8568ce536a987f6235d96103d4af6343a990
Signed-off-by: Ryan Goulding <ryandgoulding@gmail.com>
try {
PreparedStatement pstmt = conn.prepareStatement("SELECT * FROM GRANTS WHERE domainid = ? AND userid = ? AND roleid = ? ");
pstmt.setInt(1, did);
- pstmt.setInt(1, uid);
- pstmt.setInt(1, rid);
+ pstmt.setInt(2, uid);
+ pstmt.setInt(3, rid);
debug("query string: " + pstmt.toString());
ResultSet rs = pstmt.executeQuery();
if (rs.next()) {