Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
datagoblin77
Frequent Visitor

Matrix not displaying values

Hello, 

I am working on a model I did not create. The model looks at residental unit availability across a university. However, when there are no move-in or move-outs in the week, the matrix I created does not show the number of occupied units. For example on 5/26 and 6/9, I get no values (because that week features no move ins and move outs.

weekly report.png


Here are some features of the model.
I have a dim_date table that looks 12 weeks into the future. 
The  total units are calculated with:
Total Units:=DISTINCTCOUNT(Fact_Units[Unit ID])
The total occupied units are calculated with:

Total Actual Occupied Units:=
CALCULATE(
            DISTINCTCOUNT(
                         Fact_Units[Unit ID]),FILTER(Fact_Units,Fact_Units[Occupancy Flag] = "Yes"),   
                          FILTER(Dim_ProjectionsDate,Dim_ProjectionsDate[Projection Week Ending]<=MAX(Dim_ProjectionsDate[Projection                            Week Starting])))+0


The week to week projected 
Total Projected Move-Ins:= CALCULATE(DISTINCTCOUNT(Fact_Projections[Unit ID]), FILTER(Fact_Projections, Fact_Projections[Move In/Move Out] = "Move-In"))+0
Total Projected Move-Outs:= CALCULATE(DISTINCTCOUNT(Fact_Projections[Unit ID]), FILTER(Fact_Projections, Fact_Projections[Move In/Move Out] = "Move-Out"))+0

Then we calculate the week to week occupancy.

DIM_Total Projected Occupied Units:= IF(AND([Total Projected Move-Ins] = 0, [Total Projected Move-Outs] = 0), BLANK(), CALCULATE([DIM_Week Beginning Occup]+ [Total Projected Move-Ins] - [Total Projected Move-Outs]))

The BLANK() as the true condition is because in a previous iteration of the model, the matrix would arbitrarily put the initial value (total actual occupied units) 
 
I would like to change that BLANK() to the last "viable" value. 

Can anyone help?


 

2 REPLIES 2
Anonymous
Not applicable

Hi @datagoblin77 

 

Thanks for the reply from @lbendlin .

 

@datagoblin77 , for example, for 6/9, does the last valid value refer to 714?

 

My suggestion for now is that you get the max date value that is less than the current date and Total Projected Move-Ins and Total Projected Move-Outs are not 0, and then get its valid value.

 

If the problem persists, as @lbendlin said, you need to provide some data so that we can better help you. Please remove any sensitive data in advance.

 

Best Regards,
Yulia Xu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

lbendlin
Super User
Super User

To report on things that are not there you need to use disconnected tables and/or crossjoins

 

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).

Do not include sensitive information or anything not related to the issue or question.

If you are unsure how to upload data please refer to https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...

Please show the expected outcome based on the sample data you provided.

Want faster answers? https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.