Grafana - getting empty return value when my variable contains "." operator in it

I am using Grafana chained variables with infinity datasource and variable value which is passed dynamically is like this - GW12-RHEL.91

{
“Hosts”: [
“GW12-RHEL.91”
],
“Data”: {
“GW12-RHEL.91”: {
“Tx”: [
“TestTopic.1”
]
}
}
}

But when I access value by writing below query in Parsing Option, it returns empty value.

Parsing query -

Result -
image

Also, tried few other options -
Data.‘GW12-RHEL.91’.Tx
Data.${Hostname:raw}.Tx
Data.${Hostname:singlequote}.Tx

However, when I remove “.” from variable it works
Parsing Query without “.”
image

Results -
image

Can someone help me what changes do I need to do to my configuration where I am getting variable value?w

i do not see .tx in the sample data

Typo mistake. Updated json data

1 Like

The Hostname variable seems to contain the value from your initial query (specifically GW12-RHEL.91). You are encountering an issue when using this variable value to execute another query to retrieve information about that specific hostname from the data section.

Additionally, I understand that if the Hostname variable holds a value with a DOT in it, the second query does not produce any output.

I think ${Hostname:raw} should work to escape the DOT. If it’s not, then it looks like there is some issue with the Infinity Plugin.

I am not sure what parser you are using. Here is the example using backend parser where you can use JSONata based selectors. I am using ` to escape the special characters as specified in the JSONata