raintank / crate-datasource

Apache License 2.0
13 stars 8 forks source link

Templates in like #21

Open joemoe opened 8 years ago

joemoe commented 8 years ago

When using a template variable in a WHERE field with e.g. like grafana sends an unquoted string, wheres when you just type some text grafana adds quotes.

jodok commented 8 years ago
quote
joemoe commented 7 years ago

this seems to be a bit tricky.

it works whenever you use a variable on its own.

integer:

bildschirmfoto 2016-11-29 um 14 51 18 bildschirmfoto 2016-11-29 um 14 51 12

string:

bildschirmfoto 2016-11-29 um 14 50 23 bildschirmfoto 2016-11-29 um 14 50 20

combined: 💥

bildschirmfoto 2016-11-29 um 14 49 52 bildschirmfoto 2016-11-29 um 14 49 49
alexanderzobnin commented 7 years ago

Ok, I'll add unit test for this case.

sybrandy commented 7 years ago

Any progress on this? I'm trying to use a template variable and I keep getting the following error:

self.templateSrv.containsVariable

I'm using version 0.5.0 of the data source and Grafana 4.2.0.