Forum Discussion
ckhersonsky
3 years agoNew Member
Problem with Summing a Measure
Hello. I have a custom measure that references another column. If(max(Fund)=Fund1,5000,if(max(Fund)=Fund2,6000, and so on. When I sum this column, the column doesn't sum correctly at all. Wh...
- 3 years ago
Hi ckhersonsky ,
Based on your description, I have created a simple sample;
Please try:
SUM VALUE = SUMX('Table',SWITCH([Fund],"Fund1",5000,"Fund2",6000))Final output:
Best Regards,
Jianbo Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Legend_11
3 years agoResolver I
could you try this below measure?
Result =
SWITCH(
TRUE(),
MAX(Fund) = Fund1, 5000,
MAX(Fund) = Fund2, 6000,
// Add more conditions for other funds if needed
0 // Default value if no condition is met
)
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.