Dashboards & Visualizations

Dashboard not loading with error, "totalQuery is undefined"

sylim_splunk
Splunk Employee
Splunk Employee

Some of my dashboards are not loading after the 7.3.x upgrade - which were all Okay with the previous version was 7.2.6.
The error messages are different from browsers but common thing is, the dashboards are not loading with the errors.
Errors are, as below with invalid line numbers.

totalQuery is undefined or

undefined is not an object (evaluating 'totalQuery.replace')

Tags (1)
1 Solution

sylim_splunk
Splunk Employee
Splunk Employee

This is caused by some post-process searches, such as if a post-process search doesn't contain <query> element, then dashboard is not loading. This is due to JavaScript undefined error. And can be worked around by adding empty query element for the post-process searches without query. This is just a temp workaround and may not be needed once fixed (7.3.4+, 8.0.1+).

for example, below is Okay
<search base="callsA" id="myTable">
<query>
| search call_id="$token1$"
...<SNIP>
</query>
</search>

But if a post-process search doesn't have any query but only has some options, which will cause the error/symptoms (SPL-178012).
<search base="callB" id="yourTable"></search>

It can be worked around by adding empty query element as below.

<search base="callB" id="yourTable">
<query></query>
</search>

View solution in original post

sylim_splunk
Splunk Employee
Splunk Employee

This is caused by some post-process searches, such as if a post-process search doesn't contain <query> element, then dashboard is not loading. This is due to JavaScript undefined error. And can be worked around by adding empty query element for the post-process searches without query. This is just a temp workaround and may not be needed once fixed (7.3.4+, 8.0.1+).

for example, below is Okay
<search base="callsA" id="myTable">
<query>
| search call_id="$token1$"
...<SNIP>
</query>
</search>

But if a post-process search doesn't have any query but only has some options, which will cause the error/symptoms (SPL-178012).
<search base="callB" id="yourTable"></search>

It can be worked around by adding empty query element as below.

<search base="callB" id="yourTable">
<query></query>
</search>

Get Updates on the Splunk Community!

Aligning Observability Costs with Business Value: Practical Strategies

 Join us for an engaging Tech Talk on Aligning Observability Costs with Business Value: Practical ...

Mastering Data Pipelines: Unlocking Value with Splunk

 In today's AI-driven world, organizations must balance the challenges of managing the explosion of data with ...

Splunk Up Your Game: Why It's Time to Embrace Python 3.9+ and OpenSSL 3.0

Did you know that for Splunk Enterprise 9.4, Python 3.9 is the default interpreter? This shift is not just a ...