Forum Discussion
Jensej
Helper V
5 years agoCASE WHEN THEN in Measure
Hello everyone! Trying to create a measure with the IF or Switch function but can't make it work. Can someone please help me to rewrite this so it works in a measure: SUM(
CASE WHEN a....
- 5 years ago
Can you try the following formula:
Measure = ( SUMX ( Sheet1, -- Table Name IF ( Sheet1[accountNr1] = Sheet1[accountNr], CALCULATE(SUM ( Sheet1[Amount ] )), 0) ) ) - SUMX ( Sheet1, -- Table Name IF ( Sheet1[accountNr2] = Sheet1[accountNr], CALCULATE(SUM ( Sheet1[Amount ] )), 0) ) ))*-1
Jensej
Helper V
5 years agoThanks for your reply i will try but it seems there's a problem with to many ))
🙂
V-lianl-msft
Community Support
5 years agoHi Jensej ,
If the problem persists,could you share the sample data or sample pbix and the result you expected?
Please mask any sensitive data before uploading
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.