Something nice and simple. In this Tableau quick tip, we are going to walk through a simple technique for Table Pagination in Tableau, in 5 minutes or less.
Data
We will start by loading the following data into Tableau Desktop / Tableau public.
Note: If you have Tableau Desktop, you can use the Sample data source, but if you are using Tableau Public, download and load the following data source.
Calculated Fields
We only need to create the following Parameter and Calculation Fields:
Page Size Parameter
- Set Name to Page Size
- Set Data type to Integer
- Set Current value to 20
- Set Allowable values to Range
- Set Minimum to 5
- Set Maximum to 20
- Set Step size to 5
Index
INDEX()-1
Page Number
INT([Index]/[Page Size])+1
With this done, let us start creating our data visualisation.
Worksheet
We will now build our worksheet:
- Change the Mark Type to Text
- Drag Order ID onto the Rows Shelf
- Drag Order Date onto Rows Shelf
- Right-click on this pill, and select Exact Date and convert to Discrete
- Drag Customer Name onto Rows Shelf
- Drag Customer ID onto Rows Shelf
- Now double click on Sales, Quantity and Profit.
You should now see the following:
A simple table, so now we will add our pagination:
- Drag Page Number onto the Rows Shelf
- Right-click on this pill and convert to Discrete
- Drag this pill onto the Filters Shelf and select 1
You should now have the following:
You control the page size using the parameter and select your page number using the filter. My table looks like the following:
and boom, we are done… I hope you enjoyed this tutorial, and as always, you can find this data visualization on Tableau Public at https://public.tableau.com/profile/toan.hoang#!/vizhome/SimplePagination/SimplePagination
Summary
I hope you all enjoyed this article as much as I enjoyed writing it and as always do share the love. Do let me know if you experienced any issues recreating this Visualization, and as always, please leave a comment below or reach out to me on Twitter @Tableau_Magic. Do also remember to tag me in your work if you use this tutorial.
If you like our work, do consider supporting us on Patreon, and for supporting us, we will give you early access to tutorials, exclusive videos, as well as access to current and future courses on Udemy: https://www.patreon.com/tableaumagic
Just read and finished this tutorial in less than 20 minutes! Thank you as always, Toan :). How can you format the length of those parameter controls? I tried putting them as floating on dashboard but I believe you use some other ways to do it.
Hi Magician thanks for yet another wonderful dashboard, I have an issue my dashboard when change the pagesize
Your welcome, what is the issue?
The filter values are not updating automatically, could you pls help on the issue
Great great tutorial, simple and quite useful.
While changing the page number the values are added in the bottom whereas I have mention page size to be 20 so when I change the page number it should show the next 20 values rather than adding in the bottom. Can you please help whats wrong i am doing
Please send me your packaged workbook to toan.hoang@tableau.toanhoang.com and I will have a look.
Thanks for the great tutorial and the explanation was simply super.
Hi, is there anyway i can download the workbook? Thx a lot.
Hello. I dont need workbook. I got it.
Hi Tong, Nice tutorial. Is there way we can apply pagination across multiple sheets with different set of records? Our table format is same across multiple sheets. We invoke a relevant sheet with parameter on the dashboard. Page number attribute should be dynamic and showing navigate to page option (1,2,3 etc) based on set of records according to each sheet
Hello
i have implemented the same but i dont have metrics in my sheet
1. i can filter no of pages each page is 500 rows.
but few pages are showing 800, 700 etc
the no of rows are not same for each page.
can you help whats wrong here.
Thanks