Forum Discussion
Need help with DAX Measure to for Cumulative %.
- Anonymous2 years ago
I got it working: I created 2 measures:
Total Defects Part No Cumulative % =VAR CurrentRank = [DefectPartRankv2]RETURNSUMX(FILTER(ALLSELECTED('NCMDefects_Last60Days'),[DefectPartRankv2] <= CurrentRank),[Total Defects Part No])Then this one:Total Defects Part No Cumulative % All = [Total Defects Part No Cumulative %]/[Total Defects Part No All]That seemed to resolve it, I took a step back and looked at the qtys and then total qtys.Thank you for your help anyway!
Irwan How do I attach a sample file or PBIX? I do not see where I can do that? I only see pictures, I tried pasting and it would not allow me to exceed 2000 characters
- Irwan2 years ago
Super User
hello Anonymous
for dropping your pbix, please use dropbox or something similar.
also for your previous error, did you make that DAX in calculated column?
seems the error occurs because you are using measure for Cumulative calculation.
as far as i know, EARLIER function does not work with direct column in measure.
as your previous query,
the cumulative doesnt work because will always calculate the total no matter time filter you apply because you are using ALL in your DAX. ALL function will always calculate all the data you have in that respective table.
Hope this will help.
Thank you.
- Anonymous2 years agoNot applicable
Irwan what is a good email to send you the drop box link? or try this:
Not sure I understand what you are saying above. I need to use the ALL to get the % of total. The cumulative calcs refer to the % of total unless the stakeholder was doing that incorrectly, I am just trying to replicate what was done in Excel.