Forum Discussion
tejapowerbi123
6 years agoHelper V
Count based on condition
Hi Community, Please review below and provide your suggestion, I want to count organization based on “Decision”, I have used below formula and it not showing right result. Count = COUNTX( FI...
- Anonymous6 years ago
HI tejapowerbi123 ,
Create a Calculated Column
Column = CALCULATE(COUNT(Table2[Decision]),FILTER( ALLEXCEPT(Table2,Table2[Organization]), Table2[Decision] = "Award"))Regards,
Harsh NathaniAppreciate with a Kudos!! (Click the Thumbs Up Button)
Did I answer your question? Mark my post as a solution!
tejapowerbi123
6 years agoHelper V
AntrikshSharma thank you so much.I am trying to create in calculated column and i want to use column result to next formula.
AntrikshSharma
6 years agoCommunity Champion
If it is a calculated column then you can use this. Modify the IF statement as per your requirement.
Column =
VAR CurrentOrganization = RawData[Organization]
VAR RowsSatisfyingCondition =
COUNTROWS (
FILTER (
RawData,
RawData[Organization] = CurrentOrganization
&& RawData[Decision] = "Award"
)
)
VAR Result =
IF ( RawData[Decision] = "Award", RowsSatisfyingCondition )
RETURN
Result
- tejapowerbi1236 years agoHelper V
AntrikshSharma sorry still not getting the right result.
- Anonymous6 years agoNot applicable
HI tejapowerbi123 ,
Create a Calculated Column
Column = CALCULATE(COUNT(Table2[Decision]),FILTER( ALLEXCEPT(Table2,Table2[Organization]), Table2[Decision] = "Award"))Regards,
Harsh NathaniAppreciate with a Kudos!! (Click the Thumbs Up Button)
Did I answer your question? Mark my post as a solution!- tejapowerbi1236 years agoHelper V
Thank you so much one for your great suggestions.
- AntrikshSharma6 years agoCommunity ChampionYou said you are trying to create a calculated column and what you have in the image is a measure.
- tejapowerbi1236 years agoHelper V
AntrikshSharma no it is column.Thanks