Setting Multiple Thresholds in Grafana


I’m currently using Grafana with an MSSQL database as my data source, and I need to set up multiple thresholds for different gauges in the same panel.

Could someone please guide me on how to set multiple thresholds for different gauges in the same panel?
For example, in my query, the result are six gauges, and for each different “Clock_Name,” I want their thresholds to be in different values to display different colors.

[time] as ‘time’,
Precntage as ’ ’
FROM myTable
where [time] $__timeFrom() AND $__timeTo()

Any advice, examples, or insights would be greatly appreciated! Thank you in advance for your help.

Hi @shaharel

I am pretty sure that if you have multiple gauges in the same panel, you can only apply one set of thresholds to all the gauges in that panel.

Is there any reason why you cannot break up the gauges into their own separate panels, and then create the specific thresholds unique to each gauge?

Hi @grant2,

Thank you for your reply.

Yes, I can separate the gauges into their own panels. However, I need to set a dynamic threshold for each gauge, which will be taken from the SQL database. Is it possible to set a threshold from the database?

This is all I know to be written about dynamic thresholds in Grafana.

Please share sql data sample that would walk us through real world scenarios to indicate what should happen to which gauge when what data points are reached

As far as i know you can’t do it. There is a transformation config from query results that can set dynamic thresholds but only two and colours will be red-green-red fixed. We ended using a svg gauge.