Hello Everyone,
We are currently trying form a query to get the runningHours data from InfluxDb.
I have tried my best to add a sample of a data. There are two differenet measurement namely measurement_one and measurement_two.
We would like to get the data of “runningHours” with respect to time-interval(i.e. e.g. get the total running hours now()-6h separately for when the dustbinFull was true and false. In the picture. I would like to plot the values as pie chart to show the percent of runningHours in both the cases.
Thank you in advance
| _time | Measurement | _field | _value |
|---|---|---|---|
| 2023-06-22 02:00:00 GMT+2 | measurement_one | dustbinFull | TRUE |
| 2023-06-22 02:00:00 GMT+3 | measurement_one | dustbinFull | TRUE |
| 2023-06-22 02:00:00 GMT+4 | measurement_one | dustbinFull | FALSE |
| 2023-06-22 03:00:00 GMT+2 | measurement_one | dustbinFull | FALSE |
| 2023-06-22 03:00:00 GMT+3 | measurement_one | dustbinFull | FALSE |
| 2023-06-22 03:00:00 GMT+4 | measurement_one | dustbinFull | TRUE |
| 2023-06-22 04:00:00 GMT+2 | measurement_one | dustbinFull | TRUE |
| 2023-06-22 04:00:00 GMT+3 | measurement_one | dustbinFull | TRUE |
| 2023-06-22 04:00:00 GMT+4 | measurement_one | dustbinFull | FALSE |
| 2023-06-22 05:00:00 GMT+2 | measurement_one | dustbinFull | FALSE |
| _time | Measurement | _field | _value |
| 2023-06-22 02:00:00 GMT+2 | measurement_two | runningHours | 10 |
| 2023-06-22 02:00:00 GMT+3 | measurement_two | runningHours | 11 |
| 2023-06-22 02:00:00 GMT+4 | measurement_two | runningHours | 12 |
| 2023-06-22 03:00:00 GMT+2 | measurement_two | runningHours | 13 |
| 2023-06-22 03:00:00 GMT+3 | measurement_two | runningHours | 14 |
| 2023-06-22 03:00:00 GMT+4 | measurement_two | runningHours | 15 |
| 2023-06-22 04:00:00 GMT+2 | measurement_two | runningHours | 16 |
| 2023-06-22 04:00:00 GMT+3 | measurement_two | runningHours | 17 |
| 2023-06-22 04:00:00 GMT+4 | measurement_two | runningHours | 18 |
| 2023-06-22 05:00:00 GMT+2 | measurement_two | runningHours | 21 |
PS: the date show is just for an example and the timestamp values in real scenario will be always vary and they won’t be identical in both the measurement
