Table - One column per metric

Hello,
I have two metrics coming from a graphite query one is showing the inbound traffic and the other is showing the outbound traffic for different servers.

Is it possible to have one column per metric and to group them one row per specific node?

For example:

Given series like:

#A: (inbound)
server-1: 1,3,4,5,6 (the sum is 19)
server-2: 3,4,3,5,5 (the sum is 20)
server-3: 7,4,8,4,3 (the sum is 26)

#B: (outbound)
server-1: 4,3,2,6,6 (the sum is 21)
server-2: 6,5,7,4,3 (the sum is 25)
server-3: 8,7,8,7,9 (the sum is 39)

I would like to render the table in this way:

-----------------------------
|Node        |  IN  |  OUT  |
|----------------------------
|server-1    |  19  |   21  |
|----------------------------
|server-2    |  20  |   25  |
|----------------------------
|server-3    |  26  |   39  |
-----------------------------

Hi Francescor,

yes I you can do this.

  1. Add a few queries by node, eg. sum(metric_1) by node, avg(metric_2) by node
  2. At the query choose instant option and format = Table.
  3. Go to Transform tab, (tab next to query in grafana 7.0.5) add an Outer join and choose node.
  4. Add an Organize filed transform and choose which columns you want to display.
    Below is example by cluster with Prometheus datasource.

    Transform step.
1 Like