Get certified in Microsoft Fabric—for free! For a limited time, the Microsoft Fabric Community team will be offering free DP-600 exam vouchers. Prepare now
Hello. Can anyone help me with figuring out why a blank headed column appears when I run my "At risk all projects" measure? If I change what ALL() applies to, it goes away. But for some reason when I use ALL() on project names, this mysterious column appears every time. It is throwing off further calcualtions I have. See pbix screenshot below and original table.
Solved! Go to Solution.
Hi @aejohnson04 ,
How did you set your matrix visual? I create a matrix visual as below base on your provided sample data. It is different with yours...
In order to get a better understanding on your requirement and give you a suitable solution for you, could you please provide some raw data in your table (exclude sensitive data) with Text format, your matrix visual settings and your expected result with backend logic and special examples? It would be helpful to find out the solution. You can refer the following links to share the required info:
How to provide sample data in the Power BI Forum
How to Get Your Question Answered Quickly
And It is better if you can share a simplified pbix file. You can refer the following link to upload the file to the community. Thank you.
How to upload PBI in Community
Best Regards
Hi @aejohnson04 ,
I updated your sample pbix file(see the attachment), please check if that is what you want.
1. Create a date dimension table, please DO NOT create any relationship with 'Increment' table
Dates = VALUES('Increment'[Date])
2. Create two measures as below to get the culmulative values
Sum of at risk amount =
CALCULATE (
SUM ( 'Increment'[Money At Risk] ),
FILTER (
ALLSELECTED ( 'Increment' ),
'Increment'[Project Name] = SELECTEDVALUE ( 'Increment'[Project Name] )
&& 'Increment'[Date] = SELECTEDVALUE ( 'Dates'[Date] )
)
)
Culmulative values =
VAR _seldate =
SELECTEDVALUE ( 'Dates'[Date] )
RETURN
SUMX (
FILTER ( ALLSELECTED ( 'Dates'[Date] ), 'Dates'[Date] <= _seldate ),
[Sum of at risk amount]
)
3. Create a matrix visual
Best Regards
Hi @aejohnson04 ,
How did you set your matrix visual? I create a matrix visual as below base on your provided sample data. It is different with yours...
In order to get a better understanding on your requirement and give you a suitable solution for you, could you please provide some raw data in your table (exclude sensitive data) with Text format, your matrix visual settings and your expected result with backend logic and special examples? It would be helpful to find out the solution. You can refer the following links to share the required info:
How to provide sample data in the Power BI Forum
How to Get Your Question Answered Quickly
And It is better if you can share a simplified pbix file. You can refer the following link to upload the file to the community. Thank you.
How to upload PBI in Community
Best Regards
Here is a link to my pbix file:
https://drive.google.com/file/d/1q1MWjXU8Ku5M_cOQVJp3hmy2O2hMTUHJ/view?usp=sharing
I am essentially trying to create a matrix (similiar to the one you showed in your second photo) that populates the blank values with the previous non blank value. The final matrix would reflect something similar to this:
Row Labels | Plant 1 | Plant 2 | Plant3 | Grand Total |
3/23/2021 | $ 7,000.00 | $ - | $ - | $ 7,000.00 |
4/30/2021 | $ 7,000.00 | $ 1.00 | $ - | $ 7,001.00 |
11/23/2021 | $ 11,591.80 | $ 1.00 | $ - | $ 11,592.80 |
4/4/2022 | $ 184,591.80 | $ 1.00 | $ - | $ 184,592.80 |
3/1/2023 | $ 14,184,591.80 | $ 1.00 | $ - | $ 14,184,592.80 |
4/7/2023 | $ 14,184,591.80 | $ 173,001.00 | $ - | $ 14,357,592.80 |
6/28/2023 | $ 14,184,591.80 | $ 885,001.00 | $ - | $ 15,069,592.80 |
9/7/2023 | $ 14,449,183.60 | $ 885,001.00 | $ - | $ 15,334,184.60 |
6/10/2024 | $ 14,449,183.60 | $ 3,090,001.00 | $ - | $ 17,539,184.60 |
7/1/2024 | $ 14,449,183.60 | $ 3,090,001.00 | $ 20,000.00 | $ 17,559,184.60 |
7/2/2024 | $ 14,449,183.60 | $ 3,090,001.00 | $ 20,400.00 | $ 17,559,584.60 |
7/3/2024 | $ 14,449,183.60 | $ 3,090,001.00 | $ 26,400.00 | $ 17,565,584.60 |
7/4/2024 | $ 14,449,183.60 | $ 3,090,001.00 | $ 28,400.00 | $ 17,567,584.60 |
7/5/2024 | $ 14,449,183.60 | $ 3,090,001.00 | $ 29,100.00 | $ 17,568,284.60 |
7/6/2024 | $ 14,449,183.60 | $ 3,090,001.00 | $ 31,100.00 | $ 17,570,284.60 |
I believe the "running at risk" measure in the PBIX file will give me this result if I can figure out why "At risk all projects" measure is returning an extra column. You can ignore the "test" and "measure" measures. These are other tests I was trying to run to get the same solution. Thank you!
Hi @aejohnson04 ,
I updated your sample pbix file(see the attachment), please check if that is what you want.
1. Create a date dimension table, please DO NOT create any relationship with 'Increment' table
Dates = VALUES('Increment'[Date])
2. Create two measures as below to get the culmulative values
Sum of at risk amount =
CALCULATE (
SUM ( 'Increment'[Money At Risk] ),
FILTER (
ALLSELECTED ( 'Increment' ),
'Increment'[Project Name] = SELECTEDVALUE ( 'Increment'[Project Name] )
&& 'Increment'[Date] = SELECTEDVALUE ( 'Dates'[Date] )
)
)
Culmulative values =
VAR _seldate =
SELECTEDVALUE ( 'Dates'[Date] )
RETURN
SUMX (
FILTER ( ALLSELECTED ( 'Dates'[Date] ), 'Dates'[Date] <= _seldate ),
[Sum of at risk amount]
)
3. Create a matrix visual
Best Regards
AMAZING! This worked. I've been trying to get this result for so long. Thank you!!!
Now one last question, why when I try to make a stacked area chart of the same information, it only shows the actual values of the dates (aka the original table)? Is there a way to show the stacked area chart with the same values as reflected in the matrix you helped to create? The stacked area chart I am getting is below, but I would like for it to show the cumulative values (aka, Plant 1 would continue at $14M for 2023/2024)
Also, is there a way to add a totals column to the end which sums the populated values as shown in the matrix?
Check out the October 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.
User | Count |
---|---|
111 | |
94 | |
92 | |
84 | |
69 |
User | Count |
---|---|
162 | |
129 | |
126 | |
106 | |
98 |