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!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...