Tableau Filter Hierarchy
Understand how Tableau processes different filter types, how filters interact with one another, and how the order of operations affects the results displayed in a worksheet and dashboard.
1. Introduction to Filter Hierarchy
Tableau filters are used to restrict the data displayed in a visualization. They allow users to focus on specific records, categories, dates, regions or measure values according to their analytical requirements.
When multiple filters are applied to the same worksheet, Tableau evaluates them in a defined order. This sequence is known as the Tableau order of operations or filter order of execution.
Understanding this hierarchy is important because the position of a filter in the execution sequence can influence which records are available to later filters and calculations.
Why Filter Hierarchy Matters
- Helps understand how Tableau processes filters.
- Explains differences between Context and Dimension Filters.
- Helps troubleshoot unexpected visualization results.
- Improves the accuracy of analytical calculations.
- Supports better worksheet and dashboard performance.
- Helps build more reliable business reports.
2. Types of Filters in Tableau
Tableau provides several filter types. Each filter operates at a different stage of data processing and serves a specific purpose.
1. Extract Filters
Extract Filters restrict the records included when creating or refreshing a Tableau extract. They help reduce the amount of data stored in the extract.
2. Data Source Filters
Data Source Filters restrict the data available to worksheets using that data source. They are configured at the data source level.
3. Context Filters
Context Filters create a primary subset of data. Other applicable filters, such as Dimension Filters, are evaluated using this context.
4. Dimension Filters
Dimension Filters restrict categorical values such as Region, Category, Customer Name and Product Name.
5. Measure Filters
Measure Filters restrict data based on numerical measures such as Sales, Profit, Quantity or Revenue. They generally operate on aggregated measure values.
6. Table Calculation Filters
Table Calculation Filters operate after table calculations have been computed. They control which calculated results are displayed in the view.
| Filter Type | Purpose | Example |
|---|---|---|
| Extract Filter | Limits records included in an extract. | Extract only 2026 records. |
| Data Source Filter | Restricts data available from a data source. | Include only selected regions. |
| Context Filter | Creates a primary filtered subset. | Only the West region. |
| Dimension Filter | Filters categorical values. | Category = Technology. |
| Measure Filter | Filters measure values. | SUM(Sales) greater than 50,000. |
| Table Calculation Filter | Filters calculated results in the view. | Display selected rank positions. |
3. Tableau Order of Operations
Tableau follows a defined order when evaluating filters and calculations. This order is important when a worksheet contains multiple filters and calculated fields.
The following sequence shows the commonly used order of Tableau's filter and calculation operations.
4. Understanding Context Filters
A Context Filter creates a primary subset of data. Once a filter is added to context, other applicable filters are evaluated using the resulting subset.
Context Filters are especially useful when a worksheet contains multiple filters and users want one filter to define the data available to other filters.
Example
Consider a sales dataset containing records for multiple regions and product categories. If the West region is added as a Context Filter, other applicable filters work with the West region's records instead of the entire dataset.
Steps to Create a Context Filter
- Open a worksheet in Tableau.
- Drag a dimension such as Region to the Filters shelf.
- Select the required region, such as West.
- Apply the filter.
- Right-click the Region filter on the Filters shelf.
- Select Add to Context.
- Observe that the filter is displayed as a context filter.
5. Dimension Filters
Dimension Filters are used to restrict categorical data. They allow users to select specific members from fields such as Region, Category, Segment, Customer Name and Product Name.
Example: Filter by Product Category
Suppose a sales dataset contains three product categories: Furniture, Office Supplies and Technology.
If the user selects Technology in a Dimension Filter, the worksheet displays only records belonging to that category, subject to the other applicable filters.
Steps to Apply a Dimension Filter
- Open a Tableau worksheet.
- Find a dimension such as Category in the Data pane.
- Drag the dimension to the Filters shelf.
- Select the required category members.
- Click Apply or OK.
- Review the filtered visualization.
| Dimension | Selected Value | Result |
|---|---|---|
| Region | West | Only West region records |
| Category | Technology | Only Technology records |
| Segment | Corporate | Only Corporate segment records |
| Customer Name | Selected customer | Records for that customer |
6. Measure Filters
Measure Filters are used to restrict data based on numerical values. They are commonly applied to aggregated measures such as SUM(Sales), AVG(Profit) and SUM(Quantity).
Example: Filter Sales Greater Than 50,000
Consider a sales report containing different regions. A Measure Filter can be used to display only the regions whose aggregated sales values meet a selected condition.
SUM(Sales) > 50000
This expression illustrates the condition being applied to an aggregated Sales value. It is not required to create a calculated field when using Tableau's standard measure filter interface.
Steps to Apply a Measure Filter
- Open a worksheet containing a measure.
- Drag Sales to the view or Filters shelf.
- Choose the appropriate measure filtering option.
- Select the aggregation and required range or condition.
- Apply the filter.
- Review the remaining values in the visualization.
7. FIXED LOD and Filter Hierarchy
Level of Detail expressions allow Tableau users to calculate values at a specified level of detail, independently of some aspects of the current view.
FIXED LOD expressions are evaluated before ordinary Dimension Filters. This distinction can affect calculated results.
Example FIXED LOD Expression
{ FIXED [Region] : SUM([Sales]) }
This expression calculates total Sales for each Region, regardless of the dimensions currently displayed in the view.
Why the Order Matters
Consider a worksheet containing a FIXED LOD calculation and a normal Region Dimension Filter. Because FIXED LOD is evaluated before ordinary Dimension Filters, the FIXED calculation may include records that are later removed from the visible view by the dimension filter.
If a filter needs to affect the records considered by a FIXED LOD expression, adding that filter to context is a common approach.
8. Table Calculation Filters
Table Calculation Filters are applied after table calculations have been computed. They control which calculated results are displayed in the view.
For example, a worksheet may calculate the rank of products based on total Sales. A table calculation filter can then be used to display only selected rank values.
Example: Display Top 5 Ranked Products
RANK(SUM([Sales]))
This table calculation ranks products according to their aggregated Sales values. A filter based on the resulting rank can be used to display selected positions.
Steps to Apply a Table Calculation Filter
- Create a worksheet with Product Name and Sales.
- Add a table calculation such as Rank.
- Configure the calculation's addressing and partitioning.
- Create or use the required filter based on the table calculation.
- Choose the rank values to display.
- Review the resulting worksheet.
9. Practical Example: Build a Filtered Sales Report
In this practical example, we will use multiple filter types to create a sales report focused on a selected region and product category.
Sample Business Requirement
A sales manager wants to analyze Technology category sales for the West region and display only the relevant sales values.
| Filter | Configuration |
|---|---|
| Context Filter | Region = West |
| Dimension Filter | Category = Technology |
| Measure Filter | Apply the required Sales threshold |
| Visualization | Sales by Product |
Implementation Steps
- Connect Tableau to a sales dataset.
- Create a new worksheet.
- Drag Region to the Filters shelf.
- Select West and add the Region filter to context.
- Drag Category to the Filters shelf.
- Select Technology.
- Drag Product Name to Rows.
- Drag Sales to Columns.
- Apply the required measure condition if needed.
- Review the filtered sales visualization.
10. Common Filter Hierarchy Problems
| Problem | Possible Reason | Solution |
|---|---|---|
| FIXED LOD does not change after filtering | FIXED LOD is evaluated before ordinary Dimension Filters. | Check whether the filter should be added to context. |
| Dependent filter shows unexpected members | The filters may not be configured in the required hierarchy. | Review Context Filter settings. |
| Measure Filter gives unexpected results | Aggregation or view level of detail may differ. | Check the measure aggregation and worksheet structure. |
| Rank values change unexpectedly | Table calculation addressing or partitioning changed. | Review the table calculation configuration. |
| Extract contains more data than expected | Extract Filter settings may not have been applied as intended. | Review extract filters and refresh the extract if necessary. |
11. Best Practices for Filter Hierarchy
- Understand the order of operations before combining multiple filters.
- Use Context Filters only when they are needed for the analysis.
- Check FIXED LOD expressions when filter results appear unexpected.
- Use Dimension Filters for categorical data.
- Use Measure Filters for numerical and aggregated values.
- Verify table calculation addressing and partitioning.
- Test filter combinations using representative datasets.
- Keep dashboards simple and avoid unnecessary filters.
- Review performance after adding multiple filters.
Lesson Summary
Tableau Filter Hierarchy explains how different filters and calculations are evaluated during worksheet processing. Extract, Data Source, Context, Dimension, Measure and Table Calculation Filters operate at different stages.
Context Filters create a primary subset of data. FIXED LOD expressions are evaluated before ordinary Dimension Filters, while table calculation filters operate after table calculations have been computed.
Understanding the order of operations helps users troubleshoot calculations, create accurate reports and design reliable Tableau dashboards.