Forum Discussion
katemarkoska28
1 year agoFrequent Visitor
Using Field Parameters on Columns in matrix
I have this field parameter Switch = { ("Number", NAMEOF('Calculations'[ProductionLastMonth]), 0,"LastMonth",1), ("Value", NAMEOF('Calculations'[ValueProductionLastMonth]), 1,"LastMonth",1), ("Nu...
- 1 year ago
Hi katemarkoska28 ,
Please check file attach with the switch statment and a column using the name for each one on the parameter table.,
v-karpurapud
1 year agoCommunity Support
Hi katemarkoska28
Please try the below DAX:
Selected Matrix Value :=
VAR SelectedGroupLabel = SELECTEDVALUE(GroupLabelSlicer[GroupLabel])
VAR SelectedOrder = SELECTEDVALUE('Switch'[Order])
RETURN
SWITCH(
TRUE(),
SelectedGroupLabel = "LastMonth" && SelectedOrder = 0, [ProductionLastMonth],
SelectedGroupLabel = "LastMonth" && SelectedOrder = 1, [ValueProductionLastMonth],
SelectedGroupLabel = "CurrentMonth" && SelectedOrder = 2, [ProductionCurrentMonth],
SelectedGroupLabel = "CurrentMonth" && SelectedOrder = 3, [ValueProductionCurrentMonth],
BLANK()
)
If this doesn’t fully meet your needs, could you kindly share a sample of your data and more detailed context? That would help us provide a more accurate solution.
Thank You!