November 1, 2012
Tableau Tip: Passing filters in a URL (to create a dynamic report in PowerPoint)embed an image of a Tableau Dashboard in PowerPoint that updates dynamically.
This process can actually have a much broader use if you customize the URL to include filters. Let’s look at an example.
Assume you’ve created this sales dashboard.
- Create a separate dashboard for each region. Terrible idea! Way too many charts to maintain.
- Add user level security. This is easy to do with Tableau Server, but there are lots of companies that can’t afford Tableau Server. So that option could be out the window.
- Create filtered URLs and embed those in the PowerPoint via the instructions from Monday.
The link for the image for the whole dashboard is https://[YourTableauServerURL]/views/OneMinuteDashboard/OneMinuteDashboard.png. And the resulting image looks like this:
If you want a page for the Central team, you simply add ?Region=Central to the end of the URL if you are using Tableau Server. The URL now looks like this:
Notice how the Region is filtered to Central. You could embed this into PowerPoint, then duplicate the PowerPoint file and change to image to the East, etc.
You can include as many filters as you want by adding an ampersand (&) then whatever else you want to filter. The filter has to be in the format filter_name=value.
If I want a page for each Order Priority for Central, then all I do is add &Order Priority=Critical to the URL. Then replace this with High, then Medium, etc. In this example, the URL would now look like this:
And the resulting image looks like this:
Do you need to show the quick filters using this technique? No, but for me it makes the image more clear to the reader to do so. You could remove the quick filters and have the title update based on the filters. That would look good.
Finally, if you want to include multiple selections from a filter, perhaps Critical and High, then you simply add ,High to the URL.
The image now looks like this:
The filtering options are pretty endless. All you need to remember is the format for adding a filter to a URL:
?filter_name=valueI’ve created a PowerPoint with a page for each region here.