Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
niklas3000
Helper I
Helper I

How can I use synced slicers (slicer group) to set the default to last month?

Hi!

 

I trying to use "Advanced slicer syncing" to set the default value to last month for a year-month slicer.

I trying to do this by having another date-slicer set to relative, Month(Calender) and last 1.

 

By placing both slicers within the same slicer groups they are supposed to sync.

The goal is to have a Year-month-slicer, pre-set to the last month, but then the user should be able change to an earlier month if needed.

 

The data-source is a tabular-cube, so I am somewhat limited on how I can change the model. Adding measurs is possible, but not changing dimension-columns.

 

Any help is most appriciated!

 

 

 

 

1 ACCEPTED SOLUTION
v-frfei-msft
Community Support
Community Support

Hi @niklas3000,

 

Here I made one sample for your reference.

 

Measure =
IF (
    YEAR ( MAX ( Table1[date] ) ) * 100
        + MONTH ( MAX ( Table1[date] ) )
        = YEAR ( CALCULATE ( MAX ( Table1[date] ), ALL ( Table1 ) ) ) * 100
            + MONTH ( CALCULATE ( MAX ( Table1[date] ), ALL ( Table1 ) ) ),
    1,
    0
)

Then we can get the result as we excepetd. Here we need to filter the table visual by the measure.

 

1.PNG2.PNG

 

For more details, please check the pbix as attached.

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

View solution in original post

3 REPLIES 3
v-frfei-msft
Community Support
Community Support

Hi @niklas3000,

 

Here I made one sample for your reference.

 

Measure =
IF (
    YEAR ( MAX ( Table1[date] ) ) * 100
        + MONTH ( MAX ( Table1[date] ) )
        = YEAR ( CALCULATE ( MAX ( Table1[date] ), ALL ( Table1 ) ) ) * 100
            + MONTH ( CALCULATE ( MAX ( Table1[date] ), ALL ( Table1 ) ) ),
    1,
    0
)

Then we can get the result as we excepetd. Here we need to filter the table visual by the measure.

 

1.PNG2.PNG

 

For more details, please check the pbix as attached.

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Hi!

 

I have tried your example file. Thanks again for providing it. Clicking the measure does filter the visual.

 

But I cant see that the slicer sync has any effect. One of the slicer is i a group called "Group", but the other slicer is not in the same group, so they are not synced.

I am missing something?

 

 

 

 

Thanks! I will check out the pbix-file 🙂

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.