Forum Discussion
IF one value then...
- 4 years ago
Parosel , Try a measure like
Sumx(Values(Table[Client]) , Calculate(Switch( True() ,
[Percent] >= 9.195349, 2000,
[Percent] >= 8.906977,1800,
//Add others
[Percent] >= 6.6 , 200
) ) )
- 4 years ago
@Parosel please consider accepting @amitchandak solution which is tecvhnically better than yours.
@amitchandak shas wisely put the highest value first, because the switch command will trigger when it recahes the first >= true condition.
Whereas @Parosel has tested > and <.
This is two times slower and will not be True when the value is =
Well done @amitchandak !
Parosel , Try a measure like
Sumx(Values(Table[Client]) , Calculate(Switch( True() ,
[Percent] >= 9.195349, 2000,
[Percent] >= 8.906977,1800,
//Add others
[Percent] >= 6.6 , 200
) ) )
- Parosel4 years ago
Helper I
amitchandak thanks for this I applied something similar
Estimated payment at current A&G Rate = SWITCH(TRUE (),AA_Measures[A&G to OP rate] > 0.066 && AA_Measures[A&G to OP rate] < 0.0688372, "£200",AA_Measures[A&G to OP rate] > 0.0688372 && AA_Measures[A&G to OP rate] < 0.07176744186, "£400",AA_Measures[A&G to OP rate] > 0.07176744186 && AA_Measures[A&G to OP rate] < 0.07465116279, "£600",AA_Measures[A&G to OP rate] > 0.07465116279 && AA_Measures[A&G to OP rate] < 0.07753488372, "800",- speedramps4 years ago
Super User
@Parosel please consider accepting @amitchandak solution which is tecvhnically better than yours.
@amitchandak shas wisely put the highest value first, because the switch command will trigger when it recahes the first >= true condition.
Whereas @Parosel has tested > and <.
This is two times slower and will not be True when the value is =
Well done @amitchandak !