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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
Syndicate_Admin
Administrator
Administrator

Slicer by years of the Calendar of a given period.

Good

I have a question regarding the handling of dates. I have a calendar with days, ISO week numbers, ISO years...

I have a very extensive calendar from 2010 to 2050.

My goal is to get a Slicer type "Mosaic" only for the years between 2022-2025 to be able to choose separately only from these four options. I don't want the 40 years I have on the calendar to come out in the slicer.

So I put the information in a matrix and take out the slicer.

I know that the slicer has an option "Between" that you can choose the years that interest you. But this does not help me because it gives me the data of the four years together.

The problem is that what I want is a "Mosaic" type slicer and let me only choose the years from 2022 to 2025 that is the object of my study, and thus choose each year separately from only those four options.

What is the best way to get this slicer? Do I have to remove from my calendar table the years I don't need?

Thank you very much for your help.

Best regards.

2 REPLIES 2
Syndicate_Admin
Administrator
Administrator

Thanks for the reply.

But what if what I'm doing is simply visualizing the data and I'm not executing a measurement? That is, I am visualizing the data in a table without any measurement and I take out a slicer of years. How can I filter it? NOT(ISBLANK... It works only if you run a measurement.

JohnShepherdAPD
Helper II
Helper II

Hi There, I would suggest using the 'Chiclet slicer' custom visual for this, you can also add a measure as a filter to the slicer so that only the years with data are shown e.g. NOT(ISBLANK('Fact Sales'[SalesAmount])) and add additional filters to limit the selection further as required

Helpful resources

Announcements
June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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