How to build a Time Series with Time/Value/Serial_Number information

Hello every body,

I prefer tell you firstly, I’m completely new on Grafana even if my company asked me to work on.
I use Grafana v8.0.2 and I take datas from Influx bucket.

The problem is quite simple.

My flux query :
from(bucket: “bucket_dev”)
|> range(start: -1d)
|> filter(fn: (r) => r["_measurement"] == container_version")
|> filter(fn: (r) => r["_field"] == “X_Version”)
|> filter(fn: (r) => r[“company”] == “Y”)
|> keep(columns:["_time", “_value”, “serial_number”])

Give me the following result : Table with table, _time, _value, serial_number

Now I would like to have a graph like this :

But as you can see, the legend is taken in consideration the index of the table and not the serial_ number. So, I cannot see which serial_number is on which version.
This example is done by plotly plug-in but I guess it’s possible to do the same thing with TimeSeries module.

Thank you for your help in advance.

Welcome to the Grafana forums.

If your problem is still unresolved (since 9 days have passed since your original question), have you been able to produce the correct looking graph in the Influx Data Explorer? Your screenshot show the raw data table, but what does the graph in Influx look like?

Hello grant2,

No I didn’t find the solution.
This graph existed in another dashboard did by somebody in my company, and because, I guess, the bucket is different, it work well.

So, the only solution I found is to adjust data in this bucket and then use it.

For give you an aswer, I don’t arrive to plot anything similar even in Influx… probably because I don’t find how to GroupBy.