Ability to specify custom format for multi-value variables #45971
Replies: 4 comments
-
I vote for this feature. In my case, I want to add common prefix for each variable so that can be used as OpenTB query tags. Multi variables:
I want:
I got:
|
Beta Was this translation helpful? Give feedback.
-
⬆️ Upvote! ⬆️ This would be EPIC because it would allow dynamic query creation and reusability of dashboard panels. Since I am using InfluxDB (Flux language) comma delimiter does not suit my case (I need space delimiter). Here is example in text panel: I would use this feature to show different OS metrics (CPU usage, Memory, SWAP...) in same table. Currently this is not possible with multiple select dropdown because comma delimiter is automatically added in between variable values. Environment: Best regards, |
Beta Was this translation helpful? Give feedback.
-
I'm currently using Grafana v10.0.1. This is not quote the same issue/request as the OP for variable type of "custom", but mine is for variable type of "query" (using a Loki datasource), with multi-value selection. This seems to generate a list separate by a vertical pipe ("|"), but my dashboard query using the variable needs/requires the list generated by the variable to be separated by a comma (","). There is no option for the variable query to specify what delimiter character use. |
Beta Was this translation helpful? Give feedback.
-
Hello, as you may have heard, we are transitioning away from using discussions to discuss feature requests. We are migrating this discussion to an issue and closing the discussion. The issue is #83014. Feel free to continue the discussion around this there. Thank you! |
Beta Was this translation helpful? Give feedback.
-
Right now, the
raw
format option for variable use comma to separate multi-value variables. I propose to add ability to specify the delimiter and prefix, suffix for such variables.For example, to use
OR
and(
,)
as delimiter, prefix and suffix:${variable_name:raw:prefix:delimiter:suffix)}
${variable_name:raw:(: AND :)}
It will allow to construct for example sql query parts inside variables:
for example,
This variable:
will be able to translate:
to
or with multi-value:
Beta Was this translation helpful? Give feedback.
All reactions