Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
How to create a measure that will sum "Hit" and "Missed" and then will be divided to the Total.
So it will be (2350 + 150) / 6219 = 40.20% (I need percentage).
Thank you all in advance!
Solved! Go to Solution.
Hey,
I'm sorry, i forgot to mention the base measure I created and that is used in all the ohter measures:
Count Target = COUNT('Table1'[Target])
Sorry
Tom
Hi, what about:
Percentage hit or missed = CALCULATE(SUM(Table1[Count of target]);Table1[Target]="Hit" || Table1[Target]="Missed")/SUM(Table1[Count of target])
/Johan
Hi @Johanno
thanks for the quick response, unfortunately [Count of target] is not a column. It is the Target column itself.
Hey,
I created these 3 measures:
the numerator
Count Target Hit and Missed = CALCULATE( [Count Target] ,ALL('Table1'[Target]) ,OR('Table1'[Target] = "Hit", 'Table1'[Target] = "Missed") )
the denominator
Count Target ALL = CALCULATE( COUNT('Table1'[Target]) ,ALL(Table1[Target]) )
and finally the division
the Ratio = DIVIDE([Count Target Hit and Missed], [Count Target ALL], BLANK())
using all these measure on a table creates this
Maybe this is what you are looking for
Regards
Tom
Hi @TomMartens
What's the [Count Target] under the 'Count Target Hit and Missed' stands for? When I tried the formula it says that the "value for 'Count Target' cannot be determined.
Thanks
Hey,
I'm sorry, i forgot to mention the base measure I created and that is used in all the ohter measures:
Count Target = COUNT('Table1'[Target])
Sorry
Tom
Check out the September 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.