Forum Discussion
Moof
7 years agoFrequent Visitor
Using SWITCH in a Filter Context
So I'm trying to create a table that has a YTD and MTD column, based on a measure that filters from a report spec. The table I'm trying to create looks like this (apologies for the Spanish): ...
v-cherch-msft
7 years agoMicrosoft Employee
Hi Moof
In CALCULATE() function, the parameter can be a True/False expression. But you need to put a filted table context. For your requirement, you may try to use VAR Function to optimize your formula. Below is the article for your reference.
https://www.sqlbi.com/articles/variables-in-dax/
Regards,
Cherie