Introduction
The Setup
Imagine a Power BI model with two tables:- Fact_students: Contains student data, including a school_district column.
- Dim_District: A dimension table with valid school_district values.
The Problem
Why This Happens
Power BI slicers filter visuals using the dimension table. When you select blank in the slicer, Power BI applies a filter like:TREATAS({BLANK()}, 'Dim_District'[school_district])
This filter only includes fact rows that match a blank value in the dimension. But if Dim_District has no blank row, the blank fact row has no match. As a result:
- The row is excluded from the visual.
- It appears only when a measure is added, because measures evaluate over all rows, even those without matching dimension keys.
SUMMARIZECOLUMNS(ROLLUPADDISSUBTOTAL('Fact_students'[student_id], "IsGrandTotalRowTotal"),TREATAS({BLANK()}, 'Dim_District'[school_district]),"GPA_M", 'Fact_students'[GPA_M])
This query filters using the dimension, and rows without a matching key are dropped.
How to Fix It
1. Add a Blank Row to Dim_District
Include a row with a blank school_district value. This allows the blank fact row to match and be included in visuals.
2. Replace Blanks with a Default Value
Use Power Query or DAX to replace blank keys with a default like "Unknown" and add a matching row in the dimension.
3. Use Bi-Directional Filtering
Enable bidirectional filtering on the relationship. This allows the slicer to filter the fact table directly, but use with caution.
4. Use Measure-Based Logic
Design visuals around measures that include all rows, even those without matching dimension keys.
Conclusion
Blank slicer values in Power BI can be misleading. They appear because of unmatched fact rows, but don’t filter as expected unless the model supports it. Understanding how relationships and filter context work is key to building reliable, intuitive reports