Forum Discussion
How to count column with filter
I want to count column Status2020 not equal B and Status2021 = B
I use the formula as below.
COUNT(('Before 2021'[Status(2020)]),
what are you trying to do? ive reformatted it below but not sure what your objective is.
measure =
CALCULATE (
COUNT ( 'Before 2021'[Status(2020)] ),
FILTER (
'Before 2021',
'Before 2021'[Status(2020)] <> "B"
&& 'Before 2021'[Status(2021)] = "B"
)
)HI Anonymous
What's the error?
Please provide sample data.
regards
Phil
2 Replies
- vanessafvgCommunity Champion
what are you trying to do? ive reformatted it below but not sure what your objective is.
measure =
CALCULATE (
COUNT ( 'Before 2021'[Status(2020)] ),
FILTER (
'Before 2021',
'Before 2021'[Status(2020)] <> "B"
&& 'Before 2021'[Status(2021)] = "B"
)
) - PhilipTreacySuper User
HI Anonymous
What's the error?
Please provide sample data.
regards
Phil