====== Grafana ======
===== MySQL data source =====
==== Get Max/Min Value From Selected Interval ====
To get the max/min/avg-value from a selected interval in Grafana when using MySQL as data storage just add the following expression to your SQL query:
WHERE $__timeFilter()
Replace '''' with the name of your column where the time data is stored.
After that navigate to ''Value options''>''Calculation'' and select ''MAX''/''MIN''/''AVG''.
//Sourced from [[https://grafana.com/docs/grafana/latest/datasources/mysql/#table-queries|grafana.com - table queries]] and [[https://community.grafana.com/t/min-max-values-for-the-displayed-time-range/3777/4|community.grafana.com - min-max-values]]//