Data exported from backend to InfluxDB

Hello community!

I have one backend running, connected to 3 edges. When I export data from InfluxDB (exported to csv file), I get the data of all edges simultaneously and with no order, i.e. I can’t figure out which data belong to which edge.
I was wondering whether there was some kind of logic to the logging of data to the database, and how do I get data from each edge separately (through the backend of course).

Thank you,
Ghada

Hi Ghada,

OpenEMS Backend adds a ‘tag’ edge to distinguish the source Edge. You can use a query with a WHERE clause like this:

SELECT mean("_sum/GridActivePower") as "Grid"
FROM "data" WHERE ("edge" = '1') AND time > now() - 24h GROUP BY time(5m) fill(previous)

The edge tag is added here in the code:

Regards,
Stefan

1 Like