How to create an annotation every time a tag value changes?

I’m having a hard time getting something that seems conceptually very simple to work.

I just want an annotation every time the value of one of my tags changes. In this case its a software version, so I’m trying to use something like this for my annotation query:

select min(time), sw_version from latency_v2 where customer=‘SomeCustomer’ and cluster=‘SomeCluster’ group by sw_version

which would allow me a nice annotation in the charts for when a new value appears. But I’ve hit every sort of error experimenting with different variants of that notion, from empty results to time appearing only as zero, to the ‘must query something besides time…’

Can anyone more familiar with the limitations of Influx/Grafana help me out here? thanks!


Have you read the documentation?

I’m a bit unsure if you really can override the time field for annotations and therefore your requirement would not work. Maybe you can right your data in a format similar to what’s explained here.