有人可以告诉我什么是grafana“系列名称列”?

时间:2017-10-09 13:25:59

标签: grafana

我应该在<Series name column>放入什么?

我正在尝试使用饼图仪表板,我不知道在哪里可以看到相关信息。

SELECT
  UNIX_TIMESTAMP(<time_column>) as time_sec,
  <value column> as value,
  <series name column> as metric
FROM <table name>
WHERE $__timeFilter(time_column)
ORDER BY <time_column> ASC

1 个答案:

答案 0 :(得分:1)

例如,您有一个包含“server_name”,“cpu_load”,“reported_time”列的表。因此,您可以使用

进行查询
SELECT
  UNIX_TIMESTAMP(reported_time) as time_sec,
  cpu_load as value,
  server_name as metric
FROM cpu_measurements
WHERE $__timeFilter(reported_time)
ORDER BY time_sec ASC
相关问题