Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Merge selection from two slicers

Hello to all,  I am puzzled by one task and will be very glad if you could give a hint.    For simplification of the situation, let's have two tables - weekly sales and weekly brand awareness. ...
  • v-lili6-msft's avatar
    6 years ago

    hi Anonymous 

    (Alpha - in Alpha slicer, Beta - in Beta slicer)

    since Alpha and Beta and in the same column, why do you want to keep them in two separate slicers?

    Do you have set edit interaction for them to get it?

    If so, I would suggest you put them in one slicer not in two slicers, in your current way, it could not get the last two charts.

     

     

    If you still want to keep them in two separate slicers, you need two separate dim brand table, which is for Alpha and another for Beta.

    then create measure as below:

    Alpha sales = CALCULATE(SUM('weekly sales'[Sales]),FILTER('weekly sales','weekly sales'[Brand] in VALUES(Alpha[Brand])))
    Bate sales = CALCULATE(SUM('weekly sales'[Sales]),FILTER('weekly sales','weekly sales'[Brand] in VALUES(Beta[Brand])))
    sum sales = CALCULATE(SUM('weekly sales'[Sales]),FILTER('weekly sales', 'weekly sales'[Brand] in VALUES(Alpha[Brand])||'weekly sales'[Brand] in VALUES(Beta[Brand])))

     

    Of course, it has the same logic for weekly brand awareness table.

     

    here is sample pbix file, please try it.

     

    Regards,

    Lin