Grafana: global variables to access [from,to] values of the time range -


i doing tests mysql data-source , make use of timefilter inside sql query:

// query goes here... $__timefilter(time_start); 

which generates following:

where time_start >= from_unixtime(1505207821) , time_start <= from_unixtime(1505229421); 

are there variables can give me access 2 timestamps define time range?

for instance, @ example above:

from = 1505207821 = 1505229421 

yes, $__timefrom() , $__timeto() if using latest 4.5.1 version of grafana (earlier versions of grafana include alpha version of mysql data source). there "show help" button under query field macros listed. see below:

enter image description here

the first 2 macros return , in datetime format, last 2 return them epochs.


Comments

Popular posts from this blog

neo4j - finding mutual friends in a cypher statement starting with three or more persons -

php - How to remove letter in front of the word laravel -

minify - Minimizing css files -