Dashboards & Visualizations

How can I add pagination to a Dashboard Panel?

atornes
Path Finder

I have a number of panels on a dashboard that contain data tables with a large number of results. For some reason the panels also vary in the number of results that appear in the panel (i.e. 1 panel has 10 (of 60), another has 50 (of 66)) but I have nothing in the report/query that would control this. Is there a way to set pagination on these panels with a certain # of results per page?

0 Karma
1 Solution

MHibbin
Influencer

Atornes,

You will need to edit the XML of your dashboard.

You can use the following documentation for editing you simple XML (I'm assuming you have not converted to advanced XML)...
http://docs.splunk.com/Documentation/Splunk/latest/Developer/AddATable#Configure_the_table_panel
Specifically you will be looking at the table options "count" and "showPager"... i.e.

<table>
    <title>Example</title>
    <searchName>ExampleSearch</searchName>
    <fields>field1, field2, field3</fields>
    <option name="count">50</option>
    <option name="showPager">true</option>
</table>

If you have switched to advanced XML, you will need to reference the following docs...
http://docs.splunk.com/Documentation/Splunk/latest/Developer/AdvancedSearch#Add_pagination
...Specifically...

<module name="Paginator">
  <param name="entityName">events</param>
    <module name="EventsViewer"/>
</module>

Hope this helps,

Regards,

MHibbin

View solution in original post

rgcurry
Contributor

There is an error in the doc about this. What is posted by MHibbin above is correct. But in the doc section titled "Panel reference for Simplified XML" (http://docs.splunk.com/Documentation/Splunk/4.3/Developer/PanelReference]) has the following code which does NOT work:

  <showPager>(true|false)</showPager> 
0 Karma

MHibbin
Influencer

I think I see your confusion...

The syntax you have detailed above (i.e. <showPager>(true|false)</showPager>) is in the table of possible options, but if you look at the examples below the table(s) it shows the examples in the correct format (showpager is not shown here though).

Hope this helps,

MHibbin

0 Karma

MHibbin
Influencer

Atornes,

You will need to edit the XML of your dashboard.

You can use the following documentation for editing you simple XML (I'm assuming you have not converted to advanced XML)...
http://docs.splunk.com/Documentation/Splunk/latest/Developer/AddATable#Configure_the_table_panel
Specifically you will be looking at the table options "count" and "showPager"... i.e.

<table>
    <title>Example</title>
    <searchName>ExampleSearch</searchName>
    <fields>field1, field2, field3</fields>
    <option name="count">50</option>
    <option name="showPager">true</option>
</table>

If you have switched to advanced XML, you will need to reference the following docs...
http://docs.splunk.com/Documentation/Splunk/latest/Developer/AdvancedSearch#Add_pagination
...Specifically...

<module name="Paginator">
  <param name="entityName">events</param>
    <module name="EventsViewer"/>
</module>

Hope this helps,

Regards,

MHibbin

Get Updates on the Splunk Community!

Detecting Remote Code Executions With the Splunk Threat Research Team

REGISTER NOWRemote code execution (RCE) vulnerabilities pose a significant risk to organizations. If ...

Observability | Use Synthetic Monitoring for Website Metadata Verification

If you are on Splunk Observability Cloud, you may already have Synthetic Monitoringin your observability ...

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...