Browse Source

Entity Data Query -> use emptu string instead of null for latest values

pull/3293/head
Igor Kulikov 6 years ago
parent
commit
c4c65bbaeb
  1. 4
      dao/src/main/java/org/thingsboard/server/dao/sql/query/EntityDataAdapter.java

4
dao/src/main/java/org/thingsboard/server/dao/sql/query/EntityDataAdapter.java

@ -65,7 +65,7 @@ public class EntityDataAdapter {
String strValue; String strValue;
long ts; long ts;
if (entityKey.getType().equals(EntityKeyType.ENTITY_FIELD)) { if (entityKey.getType().equals(EntityKeyType.ENTITY_FIELD)) {
strValue = value != null ? value.toString() : null; strValue = value != null ? value.toString() : "";
ts = System.currentTimeMillis(); ts = System.currentTimeMillis();
} else { } else {
strValue = convertValue(value); strValue = convertValue(value);
@ -99,7 +99,7 @@ public class EntityDataAdapter {
} }
return strVal; return strVal;
} else { } else {
return null; return "";
} }
} }

Loading…
Cancel
Save