Tableau actions do not run as expected when triggering an action from a grand total or subtotal.
Grand totals and subtotals are special fields that have unique interactions with actions. Here is the behavior for a filter/parameter/set using the field being totaled when triggering an action from a subtotal:
| "Keep filtered values" after clearing selection | All values selected in filter |
| "Show all values" after clearing selection | All values selected in filter |
| "Exclude all values" after clearing selection | No values selected in filter |
| "Set value to" after clearing selection | Keep last selected value |
| "Keep current value" after clearing selection | Keep last selected value |
| Running action will "Assign values to set" | All values in set selected |
| Running action will "Add values to set" | All values in set selected |
| Running action will "Remove values from set" | Keep last selected value(s) |
Depending on the desired results, the best solution will vary. Below are some common Tableau use cases, but you can review the Tableau behavior for all action configurations in the Cause section of this article to help build a solution for other use cases.
Create a calculation that returns the sub-category the user selected, or the name of the category when the subtotal row is clicked. This value can be fed into a parameter because it is not the field being totaled, which will allow us to see which total(s) were selected.
The attached example workbook uses the sample data set Superstore to demonstrate the following directions. These directions start from "Original Dashboard." Directions to make "Original Dashboard" are embedded in the workbook.
IF MIN([Category]) != MAX([Category]) THEN 'all' ELSEIF MIN([Sub-Category]) != MAX([Sub-Category]) THEN MIN([Category]) ELSE MIN([Sub-Category]) END
CONTAINS([Click History Parameter], [Sub-Category]) OR CONTAINS([Click History Parameter], [Category]) OR CONTAINS([Click History Parameter], 'all') OR [Click History Parameter] = 'none'
Clicking on a header has the expected behavior, but teaching users to not click on totals is not a reliable solution. Instead we can replace the subtotal row with a column that contains the subtotal value.
The attached example workbook uses the sample data set Superstore to demonstrate the following directions. These directions start from "Original Dashboard." Directions to make "Original Dashboard" are embedded in the workbook.
If the desired behavior is to have nothing happen when the user clicks a total, then feeding sub-category values into a parameter action will work consistently.
The attached example workbook uses the sample data set Superstore to demonstrate the following directions. These directions start from "Original Dashboard." Directions to make "Original Dashboard" are embedded in the workbook.
CONTAINS([Sub-Category Parameter], [Sub-Category]) OR [Sub-Category Parameter] = 'none'
To voice your support for the inclusion of this enhancement in a future product release, add your vote to the following Salesforce Idea: Action Filter on Grand Totals.
001473771
1340 KB

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.