Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
I'm trying to create a measure which takes the value from each Row, and divides it by the Subtotal to give the Percentage of the Subtotal per row.
I'm currently using this measure, but it just gives a value of 100% for each row, which is wrong.
Resignation Percentage = DIVIDE(COUNT(JoinedDataTable[Reason Code]),CALCULATE(COUNTROWS(JoinedDataTable)))
The below is what it should look like:
As an example, the '18-25' Age Bracket, should calculate as 22 / 204 = 0.1078 (10.78%)
Age Bracket | Total | % |
Junior | 1 | 0.49 |
18-25 | 22 | 10.78 |
26-30 | 18 | 8.82 |
31-35 | 7 | 3.43 |
36-40 | 6 | 2.94 |
41-45 | 8 | 3.92 |
46-50 | 8 | 3.92 |
51-55 | 7 | 3.43 |
56-60 | 6 | 2.94 |
61-65 | 8 | 3.92 |
66-70 | 15 | 7.35 |
71-75 | 20 | 9.80 |
76-80 | 24 | 11.76 |
81-85 | 27 | 13.24 |
86-90 | 18 | 8.82 |
91-95 | 5 | 2.45 |
96-99 | 1 | 0.49 |
100+ | 3 | 1.47 |
Total | 204 | 100 |
Solved! Go to Solution.
Hi @LickNewin
Just small change in formula
Try this
Measure 2=
var Total= CALCULATE(COUNT(Table[Reason code]),ALLEXCEPT(Table, Table[Reason code])
Hi @LickNewin
Just small change in formula
Try this
Measure 2=
var Total= CALCULATE(COUNT(Table[Reason code]),ALLEXCEPT(Table, Table[Reason code])
Hey Uzi,
It's coming up with an error that says the Syntax for RETURN is incorrect
I think i figured it out - it was missing a closing bracket after the ALLEXCEPT
Seems to be working now!!
Thanks for your help 🙂
hi @LickNewin
you missed the closing bracket ) this one
hi @LickNewin
Try below dax for measure
Measure 1= Count ( Table[Reason code])
Measure 2=
var Total= CALCULATE(COUNT(Table[Reason code]),ALL(Table))
I hope I answered your question!
Hey Uzi,
Unfortunately that doesn't work how I wanted.
It works fine when I have all the Reason codes selected in the Filter, but as soon as I filter it, the values are wrong.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
144 | |
75 | |
63 | |
51 | |
48 |
User | Count |
---|---|
204 | |
86 | |
64 | |
59 | |
56 |