mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
Merge pull request #932 from harshanL/master
Resolved wso2/product-iots#1358
This commit is contained in:
commit
00bebe5049
@ -182,16 +182,7 @@ public class GenericOperationDAOImpl implements OperationDAO {
|
|||||||
stmt.setString(3, Operation.Status.PENDING.toString());
|
stmt.setString(3, Operation.Status.PENDING.toString());
|
||||||
// This will return only one result always.
|
// This will return only one result always.
|
||||||
rs = stmt.executeQuery();
|
rs = stmt.executeQuery();
|
||||||
int id = 0;
|
|
||||||
if (rs.next()) {
|
if (rs.next()) {
|
||||||
id = rs.getInt("ID");
|
|
||||||
}
|
|
||||||
if (id != 0) {
|
|
||||||
stmt = connection.prepareStatement(
|
|
||||||
"UPDATE DM_ENROLMENT_OP_MAPPING SET UPDATED_TIMESTAMP = ? " + "WHERE ID = ?");
|
|
||||||
stmt.setLong(1, System.currentTimeMillis() / 1000);
|
|
||||||
stmt.setInt(2, id);
|
|
||||||
stmt.executeUpdate();
|
|
||||||
result = true;
|
result = true;
|
||||||
}
|
}
|
||||||
} catch (SQLException e) {
|
} catch (SQLException e) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user