Dashboards & Visualizations

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

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

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

0 Karma

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

0 Karma
State of Splunk Careers

Access the Splunk Careers Report to see real data that shows how Splunk mastery increases your value and job satisfaction.

Find out what your skills are worth!