Dashboards & Visualizations

How to hide table visu when no results are available to dispaly

DataOrg
Builder

I am using splunk cloud 7.2.9. i want to hide a table visualization when it has no results/data from the results.

I was not able to hide a table if it has no results or empty.

0 Karma
1 Solution

vnravikumar
Champion

Hi

Try with <condition match="'job.resultCount' >0">

<dashboard>
  <label>tablecount</label>
  <row depends="$show_table$">
    <panel>
      <table>
        <search>
          <query>| makeresults 
| eval test=1 
| where test=0</query>
          <earliest>-24h@h</earliest>
          <latest>now</latest>
          <done>
             <condition match="'job.resultCount' >0">
                <set token="show_table">true</set>
            </condition>
          </done>
        </search>
        <option name="drilldown">none</option>
      </table>
    </panel>
  </row>
</dashboard>

View solution in original post

vnravikumar
Champion

Hi

Try with <condition match="'job.resultCount' >0">

<dashboard>
  <label>tablecount</label>
  <row depends="$show_table$">
    <panel>
      <table>
        <search>
          <query>| makeresults 
| eval test=1 
| where test=0</query>
          <earliest>-24h@h</earliest>
          <latest>now</latest>
          <done>
             <condition match="'job.resultCount' >0">
                <set token="show_table">true</set>
            </condition>
          </done>
        </search>
        <option name="drilldown">none</option>
      </table>
    </panel>
  </row>
</dashboard>
Get Updates on the Splunk Community!

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...

What’s New in Splunk Security Essentials 3.8.0?

Splunk Security Essentials (SSE) is an app that can amplify the power of your existing Splunk Cloud Platform, ...

Let’s Get You Certified – Vegas-Style at .conf24

Are you ready to level up your Splunk game? Then, let’s get you certified live at .conf24 – our annual user ...