I want to get answer about this discussion

Continuing the discussion from How can i set a threshold based on the comparison with the current time:

I’m fetching the last timestamp value from Elasticsearch and I want to compare it with the current time to display it in different colors.
For example, if the timestamp value is 4/25 16:00 and the current time is 4/25 16:25, the difference is within 1 hour so I want to display it in green. If the difference exceeds 1 hour, I want to display it in red.
However, I’m unsure how to incorporate a variable into the threshold value. Is there a way to do this?

Below is the current appearance of the panel I’m using.
image

  • What Grafana version and what operating system are you using?
    Grafana v10.4.2 (701c851be7)
  • What are you trying to achieve?
    Comparing current time with timestamp values to indicate color differences.
  • How are you trying to achieve it?
    set the big int value as the threshold.