mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
Fixed SQL syntax issue in DeviceStatusMonitoring Task when running on PostgreSQL.
This commit is contained in:
parent
51c18d2108
commit
8b9420766f
@ -152,7 +152,8 @@ public class OperationMappingDAOImpl implements OperationMappingDAO {
|
|||||||
"DM_DEVICE D ON E.DEVICE_ID = D.ID WHERE " +
|
"DM_DEVICE D ON E.DEVICE_ID = D.ID WHERE " +
|
||||||
"OP.STATUS IN ('"+ Operation.Status.PENDING.name() + "','" + Operation.Status.REPEATED.name() + "') " +
|
"OP.STATUS IN ('"+ Operation.Status.PENDING.name() + "','" + Operation.Status.REPEATED.name() + "') " +
|
||||||
"AND OP.CREATED_TIMESTAMP BETWEEN ? AND ? AND E.STATUS IN ('" + EnrolmentInfo.Status.ACTIVE.name() +
|
"AND OP.CREATED_TIMESTAMP BETWEEN ? AND ? AND E.STATUS IN ('" + EnrolmentInfo.Status.ACTIVE.name() +
|
||||||
"','" + EnrolmentInfo.Status.UNREACHABLE.name() + "') AND D.DEVICE_TYPE_ID = ? GROUP BY ENROLMENT_ID";
|
"','" + EnrolmentInfo.Status.UNREACHABLE.name() + "') AND D.DEVICE_TYPE_ID = ? GROUP BY ENROLMENT_ID," +
|
||||||
|
" D.DEVICE_IDENTIFICATION, E.STATUS, E.TENANT_ID";
|
||||||
stmt = conn.prepareStatement(sql);
|
stmt = conn.prepareStatement(sql);
|
||||||
stmt.setLong(1, maxDuration);
|
stmt.setLong(1, maxDuration);
|
||||||
stmt.setLong(2, minDuration);
|
stmt.setLong(2, minDuration);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user