Forum Discussion
Displaying items without data does not take into account the date filter
- 8 months ago
Hii JCASteel31
Power BI hides categories when measures return BLANK(). Instead of using “Show items without data”, use a proper star schema and measures that return 0 (via COALESCE) while driving the axis from the Calendar table. This keeps capacity visible, respects the date slicer, and avoids disconnected axis behavior.
- 8 months ago
Hi JCASteel31,
This is a classic Power BI behavior!
Here is what is happening:
The Problem: By default, visuals hide axis points (dates) where the measure returns BLANK. If your "Workload" is blank, the visual tries to collapse those dates.
The Trap: When you enable "Show items without data", you tell Power BI: "Show me ALL dates in the Calendar table, regardless of the current filter context." That is why your date slicer stops working and you see dates from 1900 to 2099.
Here is the best way to fix this while keeping your Date Slicer working:
The Solution: The "+ 0" Trick
Do not use "Show items without data." Instead, force your Workload measure to return a Zero instead of a Blank when there is no data. This forces the visual to render the date (because 0 is a value) without breaking the filter context.
Step 1: Create a new measure (or update your existing one)
Workload Display = VAR CurrentWorkload = SUM('Workload'[YourColumn]) -- Or your existing measure RETURN IF( ISBLANK(CurrentWorkload), 0, CurrentWorkload )Simple version: Workload Display = [Workload Measure] + 0
Step 2: Update the Visual
Select your chart.
Uncheck "Show items without data" on the X-axis (Date).
Replace your original Workload field with this new [Workload Display] measure.
Result:
The chart will show a "0" bar for dates with no workload.
Because the bar exists (value 0), the Capacity Line will now appear on top of it.
Because you turned off "Show items without data", the Date Slicer will work perfectly again.
Bonus Check (Data Model): Ensure your "Resource" slicer is coming from a separate Resource Dimension table (e.g., DimResources) that filters both the Workload and Capacity tables. If you filter by a column inside the Workload table, it might inadvertently hide rows in the Capacity table.
Hope this helps you visualize your capacity!
If my response resolved your query, kindly mark it as the Accepted Solution to assist others. Additionally, I would be grateful for a 'Kudos' if you found my response helpful.
This response was assisted by AI for translation and formatting purposes.
Thank you all of you for your quick answer. Just After follow your instructions, I had to deselected the date choosen in axe X and reselect the date. 😉