Forum Discussion

BrendenS's avatar
BrendenS
Frequent Visitor
2 years ago
Solved

One Slicer Selection Filters Another Slicer Selection

Hello Power BI Community,

 

I have two columns which have their own slicers on the dashboard:

AZURE_AUDIT_METRICS[Object]

AZURE_AUDIT_METRICS[Segment]

 

When a team member selects a certain Data Object I would like the Segment slicer to filter to a specific Segment automatically. One Object can have many Segments so we want to highlight (filter for) the most important Segment right away. This is best explained with an example....

 

The user selects Data Object slicer AZURE_AUDIT_METRICS[Object] = "PRA UNIT VENTURE". When this selection is made there are two Segment slicer AZURE_AUDIT_METRICS[Segment] selections available (see screenshot). We want the Segment slicer AZURE_AUDIT_METRICS[Segment] = "UNITVENTURE PUC" to be automatically selected by default when Data Object slicer AZURE_AUDIT_METRICS[Object] = "PRA UNIT VENTURE" is selected.

 

 

Thank you so much for your assistance!!

 

Brenden

  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi BrendenS ,

    Based on my testing, please try the following methods:

    1.Create the sample table.

    2.Create the new measure to display default value.

    Measure = 
       VAR selectedObject = SELECTEDVALUE('AZURE_AUDIT_METRICS'[Object])
       VAR _segment = SELECTEDVALUE(AZURE_AUDIT_METRICS[Segment])
       RETURN
           IF (
               selectedObject = "PRA UNIT VENTURE" && _segment = "UNITVENTURE PUC",
               1,
               0
           )

    3.Drag the object and segment into the slicer visual.

    4.Drag the measure into the segment slicer Filters pane. Set the show items is 1.

    5.The result is shown below.

     

    Best Regards,

    Wisdom Wu

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

1 Reply

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi BrendenS ,

    Based on my testing, please try the following methods:

    1.Create the sample table.

    2.Create the new measure to display default value.

    Measure = 
       VAR selectedObject = SELECTEDVALUE('AZURE_AUDIT_METRICS'[Object])
       VAR _segment = SELECTEDVALUE(AZURE_AUDIT_METRICS[Segment])
       RETURN
           IF (
               selectedObject = "PRA UNIT VENTURE" && _segment = "UNITVENTURE PUC",
               1,
               0
           )

    3.Drag the object and segment into the slicer visual.

    4.Drag the measure into the segment slicer Filters pane. Set the show items is 1.

    5.The result is shown below.

     

    Best Regards,

    Wisdom Wu

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.