Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi All,
Hope someone can help me with that. I'm trying to create measure which calculate % of total amount of ID's based on status (outstanding or completed). Unfortunately the way my data source is created I cannot figure out a way to do that.
Base on below data how to create % of Outstanding to show as 75% ?
ID Status
2 Outstanding
3 Close
4 Outstanding
6 Outstanding
I hope it make sense?
Thanks a lot!
This should work as a measure
Measure = DIVIDE( CALCULATE(COUNTROWS('Table1')) , CALCULATE(COUNTROWS(all(Table1)) )
Can probably do it as a calculated column if need too..
Thank you so much for replying! I've just tried that and unfortunately it's doesn't work for me.
In the 'table1' you selecting whole table, correct?
Mine Measure looks like that - but I've might have made a mistake. Would you mind have a look?
Measure = DIVIDE(
CALCULATE(COUNTROWS('ALL_DATA_x')) ,
CALCULATE(COUNTROWS(all(ALL_DATA_x[Status] ))
))
Does this looks correct?
Thanks a lot
Try these instead
Measure 1 = DIVIDE ( COUNTROWS ( 'ALL_DATA_x' ), CALCULATE ( COUNTROWS ( 'ALL_DATA_x' ), ALL ( 'ALL_DATA_x' ) ), 0 ) Measure 2 = DIVIDE ( COUNTA ( 'ALL_DATA_x'[Status] ), CALCULATE ( COUNTA ( 'ALL_DATA_x'[Status] ), ALL ( 'ALL_DATA_x' ) ), 0 )
EDIT: You may change ALL to ALLSELECTED if necessary
Thank you so much for replying! I've just tried that and unfortunately it's doesn't work for me.
In the 'table1' you selecting whole table, correct?
Mine Measure looks like that - but I've might have made a mistake. Would you mind have a look?
Measure = DIVIDE(
CALCULATE(COUNTROWS('ALL_DATA_x')) ,
CALCULATE(COUNTROWS(all(ALL_DATA_x[Status] ))
))
Does this looks correct?
Thanks a lot
Hi @mglatos,
You should add a filter in your measure. I try to reproduce using your given sample data.
If you want to calculate % of Outstanding, please add ALL_DATA_x[Status]="Outstanding" filter, please review the following formula.
Measure = DIVIDE(CALCULATE(COUNTROWS(Table5),FILTER(Table5,Table5[Status]="Outstanding")),CALCULATE(COUNTROWS(Table5),ALL(Table5)))
Format the measure as %(highlighted in red line), and create a Card visual to dislay the result.
If you have other issues, please let me know.
Best Regards,
Angelia
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
100 | |
80 | |
64 | |
58 |
User | Count |
---|---|
146 | |
110 | |
93 | |
84 | |
67 |