Forum Discussion
jpbi23
Helper I
2 years agoCalculate IF using sum and filter.
I have current Dax formula, Month 1 Recurring = CALCULATE( SUM(Master_Rev[AMOUNT]) - Master_Rev[On hold], FILTER(Master_Rev, Master_Rev[REVENUE_CATEGORY] = "Recurring" )) ...
- 2 years ago
My recommendation is to separate each revenue formula and then you can use a SWITCH formula to simplify the logic. Yes it can be written in one formula but I wouldn't recommend it.
For the Switch formula it would be:
RevenueResult = SWITCH(Mater_Rev[Region], "USA", [USAMeasure], "JPY", [JPYMeasure], "Region 3", [Region 3 Measure])
jpbi23
Helper I
2 years agoI would have to do this for various revenue categories this way. Is there a way to just do it in one formula?
ray_aramburo
Super User
2 years agoMy recommendation is to separate each revenue formula and then you can use a SWITCH formula to simplify the logic. Yes it can be written in one formula but I wouldn't recommend it.
For the Switch formula it would be:
RevenueResult = SWITCH(Mater_Rev[Region], "USA", [USAMeasure], "JPY", [JPYMeasure], "Region 3", [Region 3 Measure])