瀏覽代碼

docs: update for template variables

ref #9030
Daniel Lee 8 年之前
父節點
當前提交
f48703502d
共有 2 個文件被更改,包括 10 次插入2 次删除
  1. 5 1
      docs/sources/features/datasources/mysql.md
  2. 5 1
      docs/sources/features/datasources/postgres.md

+ 5 - 1
docs/sources/features/datasources/mysql.md

@@ -142,7 +142,11 @@ SELECT hostname FROM my_host  WHERE region IN($region)
 
 ### Using Variables in Queries
 
-Template variables are quoted automatically so if it is a string value do not wrap them in quotes in where clauses. If the variable is a multi-value variable then use the `IN` comparison operator rather than `=` to match against multiple values.
+From Grafana 4.3.0 to 4.6.0, template variables are always quoted automatically so if it is a string value do not wrap them in quotes in where clauses.
+
+From Grafana 4.7.0, template variable values are only quoted when the template variable is a `multi-value`.
+
+If the variable is a multi-value variable then use the `IN` comparison operator rather than `=` to match against multiple values.
 
 There are two syntaxes:
 

+ 5 - 1
docs/sources/features/datasources/postgres.md

@@ -154,7 +154,11 @@ SELECT hostname FROM host  WHERE region IN($region)
 
 ### Using Variables in Queries
 
-Template variables are quoted automatically so if it is a string value do not wrap them in quotes in where clauses. If the variable is a multi-value variable then use the `IN` comparison operator rather than `=` to match against multiple values.
+From Grafana 4.3.0 to 4.6.0, template variables are always quoted automatically so if it is a string value do not wrap them in quotes in where clauses.
+
+From Grafana 4.7.0, template variable values are only quoted when the template variable is a `multi-value`.
+
+If the variable is a multi-value variable then use the `IN` comparison operator rather than `=` to match against multiple values.
 
 There are two syntaxes: