Grafana-时间序列图无法使用mysql正常工作

时间:2019-11-20 12:47:47

标签: mysql panel grafana

我已经创建了一个如下表

CREATE TABLE consolationstime (TIME_elsp varchar(20),REPONSE_TIME int(11))

值类似于:

  1. 2019-11-20 08:11:00,0
  2. 2019-11-20 08:11:02,0
  3. 2019-11-20 08:11:02,6
  4. 2019-11-20 08:11:04,1
  5. 2019-11-20 08:11:04,3
  6. ................
  7. 2019-11-20 20:11:04,6

我尝试使用下面的查询来绘制图形,但是它没有按预期工作。

SELECT
  unix_timestamp(TIME_elsp) as time_sec,
  max(REPONSE_TIME) as value,
  'REPONSE_TIME' as metric
 FROM CONSOLATIONSTIME
 where REPONSE_TIME != 0
 and $__timeFilter(TIME_elsp) 
 group by TIME_elsp

current graph panel

0 个答案:

没有答案