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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
amalekshahi
Frequent Visitor

Relative Date Slicer - With some predefined date range

I need a date slicer with some predefined values:

  • Today
  • Yesterday
  • This month
  • Last month
  • Last 3 month
  • This year
  • Last year
  • Custom

Upon selecting any of these values, the from and to dates should be automatically set. Can this be done?

 

5 REPLIES 5
v-xicai
Community Support
Community Support

Hi amalekshahi,

 

Put your date on slicer visual , and there is a dropdown arrow on the upper right corner of the visual. You can choose "Relative" . Then when you select the day, month ,year and numbers, the calendar slicer that you want will show.

 

3.png

 

 

 

 

 

 

 

 

 

 

 

Best Regards,

Amy

 

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

Thanks @v-xicai  but this is not the solution I was looking for. I am familiar with the relative option in date slicer but it isn't easy to use for beginners.

Hi @amalekshahi ,

 

Could you please share your sample data or desired output screenshots for further analysis? You can also upload sample pbix to OneDrive and post the link here. Do mask sensitive data before uploading.

 

Best Regards,

Amy

Hi @v-xicai ,

 

I took a screenshot from a CRM application we use. You can find it here.

Basically selecting any option (e.g. last 7 days) will set the from and to dates to current date - 7 days and current date respectively.

Also this filter will be set against the date dimension's date column.

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

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