I need to extract data from my influxdb v2.7 where the extract is a more normalized table.
I have tried doing an extract like this
influx query 'from(bucket: "sports") |> range(start:-30m) |> filter(fn: (r) => r["_measurement"] == "wallets")'
However, this data is not formatted to my expectations, the output is like:
_start:time _stop:time _field:string _measurement:string _time:time _value:int
Where each row corresponds to a specific field in the measurement. However, I would like each row to be an entire data point of the measurement. Say my measurement has 3 fields, “aaa”, “bbb”, “ccc”, I want my extraction to be like:
aaa|bbb|ccc|time
vala|valb|valc|12/31/2020T10:30
vaa|bbb|cawd|12/31/2020T10:40
aa|bwbb|cadwd|12/31/2020T10:50
Something that is more comparable to a standard database. How can I accomplish this?