Influx:Show field keys based on tag values (or the other way)
1
vote
0
answers
357
views
I have an influx database with one tag key (called machine) and multiple field key (called cpu and memory). I want to be able to find all unique tag values for each field key or filled field keys for a given tag value.
Here is an example of database:
SELECT * FROM "myMeasurement"
name: myMeasurement
-------------------
time machine cpu memory
2020-01-01T00:00:00Z m1 51
2020-01-01T01:00:00Z m2 2048
2020-01-01T00:00:00Z m1 52
2020-01-01T01:00:00Z m2 2054
I would like to retrieve **m1** when requesting machine containing **cpu** values and/or **cpu** when requesting not empty field keys for machine **m1**.
Thanks
Asked by Pierre S.
(111 rep)
Aug 5, 2020, 10:52 AM