You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
SELECTtimestamp*0.001as time_sec,
data.valueas value,
properties.valueas metric
FROM data
LEFT JOIN properties ON (properties.entity_id=data.channel_id)
LEFT JOIN entities ON (entities.id=data.channel_id)
WHERE
(channel_id =1|| channel_id =2|| channel_id =3) AND
(timestamp) >= $__unixEpochFrom() *1000AND
(timestamp) <= $__unixEpochTo() *1000ANDproperties.pkey='title'ORDER BYtimestampASC
Using channel names
SELECTtimestamp*0.001as time_sec,
data.valueas value,
properties.valueas metric
FROM data
LEFT JOIN properties ON (properties.entity_id=data.channel_id)
LEFT JOIN entities ON (entities.id=data.channel_id)
WHERE
(properties.value="Flur"||properties.value="Werkstatt" ) AND
(timestamp) >= $__unixEpochFrom() *1000AND
(timestamp) <= $__unixEpochTo() *1000ANDproperties.pkey='title'ORDER BYtimestampASC
Using UUID
SELECTtimestamp*0.001as time_sec,
data.valueas value,
properties.valueas metric
FROM data
LEFT JOIN properties ON (properties.entity_id=data.channel_id)
LEFT JOIN entities ON (entities.id=data.channel_id)
WHERE
(uuid ="12345678-1234-1234-1234-1234567890ab"|| uuid ="12345678-1234-1234-1234-1234567890ac" ) AND
(timestamp) >= $__unixEpochFrom() *1000AND
(timestamp) <= $__unixEpochTo() *1000ANDproperties.pkey='title'ORDER BYtimestampASC