Forum Discussion
Anonymous
7 years agoNot applicable
Switch (True().....) not showing the correct result
Hi Power BI Community,
I am creating a Dax formula with Switch (True()) case:
Nested If = SWITCH (TRUE (),
Data[Margine C] <= 0.00, "<=0%",
Data[Margine C] <=15.00, ">=0% <15%",
Data[Margine C] <=20.00, ">=15% <20%",
Data[Margine C] <=30.00, ">=20% <30%",
Data[Margine C] <=50.00, ">=30% <50%",
Data[Margine C] > 50.00, ">= 50%"
)
But when I am using this column in Slicer, it is showing me only Two value
Please let me know, where I am wrong in the formula?
Anonymous
Try this one
Nested If = SWITCH ( TRUE (), Data[Margine C] <= 0.00, "<=0%", Data[Margine C] <= 0.15, ">=0% <15%", Data[Margine C] <= 0.20, ">=15% <20%", Data[Margine C] <= 0.30, ">=20% <30%", Data[Margine C] <= 0.50, ">=30% <50%", Data[Margine C] > 0.50, ">= 50%" )
2 Replies
- Zubair_MuhammadCommunity Champion
Anonymous
Try this one
Nested If = SWITCH ( TRUE (), Data[Margine C] <= 0.00, "<=0%", Data[Margine C] <= 0.15, ">=0% <15%", Data[Margine C] <= 0.20, ">=15% <20%", Data[Margine C] <= 0.30, ">=20% <30%", Data[Margine C] <= 0.50, ">=30% <50%", Data[Margine C] > 0.50, ">= 50%" )- AnonymousNot applicable
@ Zubair_Muhammad, thank you it worked.