You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|*$__timeFilter(columnName)*| Replaced by a conditional that filters the data (using the provided column) based on the time range of the panel in seconds |`timestamp >= cast(1706263425598000 as timestamp) AND timestamp <= cast(1706285057560000 as timestamp)`|
121
-
|*$__fromTime*| Replaced by the starting time of the range of the panel cast to timestamp |`cast(1706263425598000 as timestamp)`|
122
-
|*$__toTime*| Replaced by the ending time of the range of the panel cast to timestamp |`cast(1706285057560000 as timestamp)`|
123
-
|*$__sampleByInterval*| Replaced by the interval followed by unit: d, h, s or T (millisecond). Example: 1d, 5h, 20s, 1T. |`20s` (20 seconds) , `1T` (1 millisecond) |
124
-
|*$__conditionalAll(condition, $templateVar)*| Replaced by the first parameter when the template variable in the second parameter does not select every value. Replaced by the 1=1 when the template variable selects every value. |`condition` or `1=1`|
|_$\_\_timeFilter(columnName)_| Replaced by a conditional that filters the data (using the provided column) based on the time range of the panel in seconds |`timestamp >= cast(1706263425598000 as timestamp) AND timestamp <= cast(1706285057560000 as timestamp)`|
124
+
|_$\_\_fromTime_| Replaced by the starting time of the range of the panel cast to timestamp |`cast(1706263425598000 as timestamp)`|
125
+
|_$\_\_toTime_| Replaced by the ending time of the range of the panel cast to timestamp |`cast(1706285057560000 as timestamp)`|
126
+
|_$\_\_sampleByInterval_| Replaced by the interval followed by unit: d, h, s or T (millisecond). Example: 1d, 5h, 20s, 1T. |`20s` (20 seconds) , `1T` (1 millisecond)|
127
+
|_$\_\_conditionalAll(condition, $templateVar)_| Replaced by the first parameter when the template variable in the second parameter does not select every value. Replaced by the 1=1 when the template variable selects every value. |`condition` or `1=1`|
125
128
126
129
The plugin also supports notation using braces {}. Use this notation when queries are needed inside parameters.
127
130
128
-
Additionally, Grafana has the built-in [`$__interval` macro][query-transform-data-query-options], which calculates an interval in seconds or milliseconds.
129
-
It shouldn't be used with SAMPLE BY because of time unit incompatibility, 1ms vs 1T (expected by QuestDB). Use `$__sampleByInterval` instead.
131
+
Additionally, Grafana has the built-in [`$__interval` macro][query-transform-data-query-options], which calculates an interval in seconds or milliseconds.
132
+
It shouldn't be used with SAMPLE BY because of time unit incompatibility, 1ms vs 1T (expected by QuestDB). Use `$__sampleByInterval` instead.
130
133
131
134
### Templates and variables
132
135
@@ -144,12 +147,12 @@ Ad hoc filters allow you to add key/value filters that are automatically added
144
147
to all metric queries that use the specified data source, without being
145
148
explicitly used in queries.
146
149
147
-
By default, Ad Hoc filters will be populated with all Tables and Columns. If
150
+
By default, Ad Hoc filters will be populated with all Tables and Columns. If
148
151
you have a default database defined in the Datasource settings, all Tables from
149
152
that database will be used to populate the filters. As this could be
150
153
slow/expensive, you can introduce a second variable to allow limiting the
151
154
Ad Hoc filters. It should be a `constant` type named `questdb_adhoc_query`
152
-
and can contain: a comma delimited list of tables to show only columns for one or more tables.
155
+
and can contain: a comma delimited list of tables to show only columns for one or more tables.
153
156
154
157
For more information on Ad Hoc filters, check the [Grafana
0 commit comments