Forum Discussion
rmbuchan
3 years agoFrequent Visitor
How to stop the Switch Function from replacing a calculated value with a null value
Hello All, I could use help with the Switch ( TRUE () function. If I use a calculated value the switch result is null However, if I hardcode a number in the switch instead of the ...
- 3 years ago
Hi rmbuchan
Your [PL Actuals] measure is told to return the value of [Income] when the row index is 3.
[Income] calculates [PL Values] when the Category is Income. This is the problem. The Category for rows with row index 3 is Total Income. That's why you're getting a blank here.
You can fix the issue by modifying this line in the SWITCH to
CRSindex = 3, CALCULATE([PL Values], 'RPT Income Statement'[Category] = "Total Income"),Regards
Phil
v-henryk-mstf
Community Support
3 years agoHi rmbuchan ,
Whether the advice given by PhilipTreacy has solved your confusion, if the problem has been solved you can mark the reply for the standard answer to help the other members find it more quickly. If not, please point it out.
Looking forward to your feedback.
Best Regards,
Henry