|
|
@ -93,8 +93,11 @@ public class PostgreSQLDeviceDAOImpl extends AbstractDeviceDAOImpl {
|
|
|
|
|
|
|
|
|
|
|
|
if (serial != null) {
|
|
|
|
if (serial != null) {
|
|
|
|
sql = sql + "FROM DM_DEVICE d, DM_DEVICE_TYPE t, DM_DEVICE_INFO i " +
|
|
|
|
sql = sql + "FROM DM_DEVICE d, DM_DEVICE_TYPE t, DM_DEVICE_INFO i " +
|
|
|
|
"WHERE DEVICE_TYPE_ID = t.ID AND d.ID= i.DEVICE_ID " +
|
|
|
|
"WHERE DEVICE_TYPE_ID = t.ID " +
|
|
|
|
"AND i.KEY_FIELD='serial' AND i.VALUE_FIELD = ? AND d.TENANT_ID = ? ";
|
|
|
|
"AND d.ID= i.DEVICE_ID " +
|
|
|
|
|
|
|
|
"AND i.KEY_FIELD = 'serial' " +
|
|
|
|
|
|
|
|
"AND i.VALUE_FIELD = ? " +
|
|
|
|
|
|
|
|
"AND d.TENANT_ID = ? ";
|
|
|
|
isSerialProvided = true;
|
|
|
|
isSerialProvided = true;
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
sql = sql + "FROM DM_DEVICE d, DM_DEVICE_TYPE t WHERE DEVICE_TYPE_ID = t.ID AND d.TENANT_ID = ? ";
|
|
|
|
sql = sql + "FROM DM_DEVICE d, DM_DEVICE_TYPE t WHERE DEVICE_TYPE_ID = t.ID AND d.TENANT_ID = ? ";
|
|
|
|