Filters &
Filter Order
Master how Tableau filters your data at every stage: from extract to table calc. Understand the critical order of operations that determines what you see.
What Is a Filter?
A filter is a rule that removes rows or values from your data before (or after) Tableau builds a visualization. Think of it as a gatekeeper: only data that passes the filter's condition appears in your chart.
Why Filter Order Matters
Tableau applies filters in a strict sequence: not all at once. A filter applied early removes data before later calculations can see it. This means the same filter condition can produce different results depending on where in the pipeline it is placed.
Dimension vs Measure Filters
The Tableau Filter Pipeline
Extract & Data Source Filters
Context Filters
A context filter creates a temporary, smaller dataset that all other filters in the view operate on. It runs at step 3: after data source filters but before dimension and measure filters.
Dimension Filters: Include or Exclude
Dimension filters (step 4) let you select specific members of a categorical field. Tableau evaluates these before aggregating measures.
Measure Filters: Numeric Thresholds
Measure filters (step 5) apply after aggregation. Tableau first computes the aggregate (SUM, AVG, etc.), then checks if the result passes the filter condition.
Table Calculation Filters
Table calc filters (step 6) are the last filters applied. They hide marks from the view after all other calculations (including running totals, ranks, and percent of total) have been computed.
Key Distinction: Dimension vs Measure
| Dimension Filter | Measure Filter | |
|---|---|---|
| Acts on | Individual category members | Aggregated numeric values |
| Pipeline step | Step 4 | Step 5 |
| Example | Keep only "West" region | \( \text{SUM(Sales)} > \$10,000 \) |
| Runs before aggregation? | Yes | No (after) |
| Changes totals? | Yes: removes rows | Yes: removes marks |
| UI appearance | Checkboxes or list | Slider or range input |
How to Apply Filters in Tableau
Example 1: Dimension Filter
Scenario: You have sales data for 4 regions. You only want to see East and West in your bar chart.
Example 2: Measure Filter
Scenario: You want to show only product sub-categories where \( \text{SUM(Profit)} > \$5,000 \).
Example 3: Context Filter + Top N
Scenario: Show the Top 5 products by Sales in the West region only.
Common Mistakes
Filter Order Summary
| Step | Filter Type | When It Runs | Effect |
|---|---|---|---|
| 1 | Extract | At extract creation | Permanently removes rows |
| 2 | Data Source | On connection | Limits all sheets |
| 3 | Context | Before dimension filters | Creates subset for Top N |
| 4 | Dimension | Before aggregation | Removes categorical members |
| 5 | Measure | After aggregation | Removes marks by value |
| 6 | Table Calc | After all calculations | Hides marks, keeps calcs intact |
Question 1 of 5
Which filter type is applied earliest in Tableau's order of operations?
Question 2 of 5
A dimension filter on \( \text{Region} = \text{"West"} \) is applied at step 4. What happens to \( \text{SUM(Sales)} \)?
Question 3 of 5
You want to show the Top 5 products by Sales within the West region. You add a Top 5 filter and a Region filter. The result shows fewer than 5 products. What went wrong?
Question 4 of 5
What is the key difference between a measure filter and a table calculation filter?
Question 5 of 5
You filter out the #1 ranked product using a table calculation filter. What happens to the product that was ranked #2?