bugfix
This commit is contained in:
parent
69544b4552
commit
b6e902feb6
2 changed files with 2 additions and 2 deletions
|
|
@ -54,7 +54,7 @@ public class Event extends AbstractDevice<HalEventConfig,HalEventData>{
|
|||
|
||||
if (getId() != null) {
|
||||
PreparedStatement stmt = db.getPreparedStatement(
|
||||
"SELECT data FROM event_data_raw WHERE event_id == ? ORDER BY timestamp DESC LIMIT 1");
|
||||
"SELECT * FROM event_data_raw WHERE event_id == ? ORDER BY timestamp DESC LIMIT 1");
|
||||
stmt.setLong(1, getId());
|
||||
return (HalEventData)
|
||||
DBConnection.exec(stmt, new DeviceDataSqlResult(deviceDataClass));
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ public class Sensor extends AbstractDevice<HalSensorConfig,HalSensorData>{
|
|||
|
||||
if (getId() != null) {
|
||||
PreparedStatement stmt = db.getPreparedStatement(
|
||||
"SELECT data FROM sensor_data_raw WHERE sensor_id == ? ORDER BY timestamp DESC LIMIT 1");
|
||||
"SELECT * FROM sensor_data_raw WHERE sensor_id == ? ORDER BY timestamp DESC LIMIT 1");
|
||||
stmt.setLong(1, getId());
|
||||
return (HalSensorData)
|
||||
DBConnection.exec(stmt, new DeviceDataSqlResult(deviceDataClass));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue