How to use a template variable in annotations queries

In a dashboard using template variables, I would like to filter the events to show only revelant annotations.
I tried to use this query :
select title,tags,text from events WHERE $timeFilter and projet=’$project’ and env=’$env’
where $project and $env are my dashboard template variables.
Is it possible to do that like this?
What am I doing wrong?

1 Like


That should be possible. Are you getting any errors?

Can it be that you’ve a type of projet instead of project in your where expression?


I am having a similar problem.
My row is using template variable $Vessel.
When i pick multiple $Vessels i get multiple rows, each showing the correct information,
I have another table ‘Events’ that all my annotations are stored in.
My annotation query is
SELECT * FROM “EVENTS” WHERE (“SITE” = ‘MashPaddle’ AND “Vessel” =~ /^$Vessel/) AND $timeFilter

When i pick a single vessel and show a single row all works correctly.
if i pick multiple vessels and have multiple rows, the annotations are not filtered and All Annotations show up on all Rows / Graphs

I am seeing the same issue.
Annotations are not getting filtered by host variable (and host =~ /^$host/), and all Annotations shows up on all Rows/Graphs.
Were you able to find or get a solution or workaround?

Not yet just disabled them.

Best regards,

Robert Budgen

Business Development Manager: Process Control Solutions

Bürkert Fluid Control Systems

Burkert Contromatic Inc.

5002 South Service Road

Burlington ON L7L 5Y7

Cell: (905) 630-0694

Phone: (905) 632-3033

Fax: (905) 632-3833