Forum Discussion
Anonymous
8 years agoNot applicable
Multiple condition in if
hello , please i need some help here what i have if ( ca = 0 ) in date1 and ca <>0 in date2 then 'new' else if ( ca in date1 < ca in date2 ) then 'up') else if (ca in date 1 > ca in date then 'd...
- 8 years ago
Hello, Switch should be perfect.
I assume two measures,
CA1 for ca in date1 and CA2 for ca in date2.
Switch(
TRUE(),
[CA1]=0 && [CA2]<>0, 'new', --condition 1
[CA1]>[CA2], 'up', --condition 2
[CA1]<[CA2], 'down' --condition 3
[CA1]<>0 && [CA2]=0, 'unknown' --condition 4
BLANK()) --elseFor further information check this article.
I hope this helps. I want miss the SWITCH function anymore.
Greg_Deckler
8 years agoCommunity Champion
Can you post an example of your data? I don't understand ca=0 in date1?
Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490
- Anonymous8 years agoNot applicable
i have problem to access to my data but 'CA' it's a measure ; an amount and date1 is a date from Dimension date that's why i called date1 because i have with 2 date that's why