Forum Discussion
Display lowest Hierarchy slicer field selected
- 7 years ago
Anonymous
May be.. something like this.
Checking if the lowest level is filtered>>then next upper level>>then next
See the attached sample file as well
Measure = SWITCH ( TRUE (), ISFILTERED ( Table1[Level3] ), CONCATENATEX ( VALUES ( Table1[Level3] ), [Level3], "," ), ISFILTERED ( Table1[Level2] ), CONCATENATEX ( VALUES ( Table1[Level2] ), [Level2], "," ), ISFILTERED ( Table1[Level1] ), CONCATENATEX ( VALUES ( Table1[Level1] ), [Level1], "," ) ) - 7 years ago
Anonymous
I see that order of levels 2 and 3 in your MEASURE was not correct.
Use this MEASURE
Selectedslicer = SWITCH ( TRUE (), ISFILTERED ( FACT_UTE[Employee] ), SELECTEDVALUE ( FACT_UTE[Employee] ), ISFILTERED ( FACT_UTE[SG_Code] ), SELECTEDVALUE ( FACT_UTE[SG_Code] ), ISFILTERED ( FACT_UTE[OC] ), SELECTEDVALUE ( FACT_UTE[OC] ), ISFILTERED ( FACT_UTE[Region] ), SELECTEDVALUE ( FACT_UTE[Region] ), "Select a value" )
Anonymous
I see that order of levels 2 and 3 in your MEASURE was not correct.
Use this MEASURE
Selectedslicer =
SWITCH (
TRUE (),
ISFILTERED ( FACT_UTE[Employee] ), SELECTEDVALUE ( FACT_UTE[Employee] ),
ISFILTERED ( FACT_UTE[SG_Code] ), SELECTEDVALUE ( FACT_UTE[SG_Code] ),
ISFILTERED ( FACT_UTE[OC] ), SELECTEDVALUE ( FACT_UTE[OC] ),
ISFILTERED ( FACT_UTE[Region] ), SELECTEDVALUE ( FACT_UTE[Region] ),
"Select a value"
)
Wow! Thank you so much Zubair_Muhammad you're a life saver, it worked great I failed to see my mistake thank you!
- Marcin6 years ago
Helper V
I am looking for help with similar case, I need to create a measure which will return selected value from hierarchy slicer but only when there is only one selected.
When there is more than one value selected it should return BLANK.
In this example it should return BLANK :
In this selection it shoudl return 20 :
In this example it should return 110:
I wil be grateful for help.