All, I am trying to create a couple of tables with multiple metrics and values, with each row being a different metric. That’s the easy part. However, some of the data I want to pull has a lot of different values/options in the tree, where I a) don’t want to manually enter each one into the table and b) only show metrics that are greater than 0.
Question 1: Is it possible to automatically create a table with all child metrics underneathe a given parent metric. Simplistic example being I have a parent a Fruit and underneathe would be all metrics and values of type of fruit.
Question 2: Is it possible to only show the metrics that have non-zero values in them?
Thanks in advance
Hi,
I get the impression that you may have misunderstood the key concepts of influxdb, please read it. A table in influxdb is a “measurement”. As far as I understand influxdb don’t support parent/child (hierarchical) data.
If I understand you correctly you want to be able to define something like this:
time value_1 value_2 option
2015-08-18T00:00:00Z 12 null abc
2015-08-18T00:00:00Z null 1 def
2015-08-18T00:00:00Z 13 14 ghi
As far as I understand influxdb does not support null values, but I may be wrong. So you maybe need to rethink your solution and use several measurements and/or write all your values/options that you want to display/filter on.
In Grafana you can hide series that have a value of zero, see screenshot:
This will be made on client side which in some cases may not be what you want (if you have a lot of data). In that case you should be able to filter out zero values in your influxdb query using the WHERE clause.
Marcus