Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
7 years ago
Solved

Tricky switch FUCNITON

Hi Experts

 

would it be possible to use the switch function to change two measure at the same time.....when a paricular selection is made using a slicer.... this is what i have done so far...

 

Set up a discount table with no relationship to the main fact table and using the following switch

 

Change measure with slicer = If (ISCROSSFILTERED((discount table [measure]), Switch (TRUE (),

Values (discount table [measure]) = “NOE”, [Measure1],

Values (discount table [measure]) = “Reported”, [Measure2],

Blank()),Blank())

 

Displays blank graph. If nothing is selected…

[Measure 1] = AOP && PY

  • Anonymous

    Try this,

     

    Final =
    var _Infilter = CONCATENATEX(VALUES(discount table [measure]),discount table [measure],"-")

    Return SWITCH(_Infilter,
    "Mes1",[Mes1],
    "Mes2",[Mes2])

     

    Let me know if it is not solved your proble. 

1 Reply

  • Baskar's avatar
    Baskar
    Resident Rockstar

    Anonymous

    Try this,

     

    Final =
    var _Infilter = CONCATENATEX(VALUES(discount table [measure]),discount table [measure],"-")

    Return SWITCH(_Infilter,
    "Mes1",[Mes1],
    "Mes2",[Mes2])

     

    Let me know if it is not solved your proble.