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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Adamant98
New Member

Slicer Monthly

Looking for some help, Is there a way I can do a slicer for a monthly select, I can do it via days, it works somewhat with reletive date however I want it more like this.

 

How it currently is

Adamant98_1-1708691390109.png

 

How I want it but in months

Adamant98_2-1708691454934.png

Been trying to figure out for some days now, I may have to just go back and edit my excel file and add another collum for month but surly with just having a date in there it should be possible to do it without.

 

Any help would be great.

 

Thanks

 

3 REPLIES 3
Ritaf1983
Super User
Super User

Hi @Adamant98 
You need to create a calendar table with the needed columns.

Please refer to the linked article, it also includes the needed scripts:

https://radacad.com/do-you-need-a-date-dimension

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

 

jolind1996
Resolver II
Resolver II

Yes, there is a way to create a slicer for a monthly select in Power BI. You can do this by using the date hierarchy in the slicer visual. Here's how you can do it:

  1. Open the Power BI desktop and load your data using the Get Data option.
  2. Once the data has been loaded, select the slicer icon presented in the visualization pane.
  3. In the slicer visual, drag and drop the date field that you want to use for the slicer.
  4. In the field well, select the down arrow next to the date field and choose the "Date Hierarchy" option.
  5. Expand the date hierarchy and select the "Month" level.

This will create a slicer that allows you to filter your data by month. You can now select the desired month in the slicer to filter your data accordingly.

 

Alternatively, you can create a new column or measure in your data model that extracts the month from the date column using a formula like Month([Date Column]), where [Date Column] represents the name of the column where the date is located. Once you have created the new column or measure, you can add it to your Power BI slicer and filter your data based on the month by selecting the relevant month in your slicer.

 

Best regards,

Johannes

Adamant98_0-1708692345181.png

I dont seem to have Date Hierarchy as an option

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Power BI Monthly Update - May 2024

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