Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
I'm not sure if Switch is the right function I would need to use or not, but basically I'm looking to make it to where "Health 4 All" could change with a filter or a table selection. I'd like to be able to select a different option, and have it change inside my formulas.
Is Switch the function I would want to use, or would this need to be a VAR function?
Need help!
Solved! Go to Solution.
Hi @Ahead4097 ,
I noticed that you have used some IF() functions, so you could replace it with SWITCH() function.
For example:
SWITCH(
TRUE(),
[Measure] = "YOUR CONDITION1",
RESULT1 YOU NEED,
[Measure] = "YOUR CONDITION2",
RESULT2 YOU NEED
)
Hi @Ahead4097 ,
I noticed that you have used some IF() functions, so you could replace it with SWITCH() function.
For example:
SWITCH(
TRUE(),
[Measure] = "YOUR CONDITION1",
RESULT1 YOU NEED,
[Measure] = "YOUR CONDITION2",
RESULT2 YOU NEED
)
Can you provide a sample of data and show what your filters would look like and the expected result?
DAX is for Analysis. Power Query is for Data Modeling
Proud to be a Super User!
MCSA: BI ReportingI've attached some photos of the slicer, the data sample, and the end result.
I have multiple measures that are using the Subject "Health 4 All" as a filter. I'm trying to get it to where I'll be able to slice the Subject, and "Health 4 All" will change in each of my measures to the selected Subject.
Sorry for all the black...had to scrub.
Measure examples: