Forum Discussion
vwiles84
Helper III
2 years agoCalculate measure with If Statement
I am trying to write a calculation that if the Year is 2023 and the months are March and April, don't include those numbers in the sum. If have the filter working for the month but need to include c...
- Anonymous2 years ago
Hi vwiles84 ,
Here some steps that I want to share, you can check them if they suitable for your requirement.
Here is my test data:Create a measure
Donation QTY Minus MarApril = CALCULATE( SUM('Table'[Value]), FILTER( 'Table', 'Table'[Year] <> 2023 || ('Table'[Month]<> "April" && 'Table'[Month]<>"March") ) )Final output
Best regards,
Albert He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Anonymous
2 years agoNot applicable
Hi vwiles84 ,
Here some steps that I want to share, you can check them if they suitable for your requirement.
Here is my test data:
Create a measure
Donation QTY Minus MarApril =
CALCULATE(
SUM('Table'[Value]),
FILTER(
'Table',
'Table'[Year] <> 2023 || ('Table'[Month]<> "April" && 'Table'[Month]<>"March")
)
)
Final output
Best regards,
Albert He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly