Search code examples
grafanainfluxdb

Display 20 curves in the same grafana panel 1 curve x user


I am using InfluxDB and grafana. I have a data for 20 users.

Here is the query I use to display a single user:

SELECT delta  FROM "measures" WHERE user_id='23545296664228' 

What I want is a panel in Grafana when I can display all 20 series ?

Ideally, it would be great to be able to display/hide series to focus on a specific one.

The goal, here, is to see if there is a specific user that behaves differently from others, and be able to visually identify him

Is it possible ?


Solution

  • Assuming user_id is tag in measures measurement you need to use group by in query like in this example:

    SELECT delta  FROM "measures"  WHERE time > now() - 1d GROUP BY time(1h),user_id