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

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now

Reply
nisha_deepak
Helper III
Helper III

Slicer creation based on policy expiry date

Capture.PNG

 

This is the field i used from data source for creating report.My requirement is i need a slicer which contains values like 30 days,60 days,90 days,120 days.When i select 30 days data will show based on policy_expiry_date which contains date expired within last 30 days compare with current date.Like wise 60 days means date expired within last 60 days compare with current date.Example,current date is (01-11-2020),so when i select 30days from slicer value will show from today to last 30 days.When i select 60 days from slicer data will show from today to last 60 days data.

 

Capture2.PNG

1 ACCEPTED SOLUTION
Anonymous
Not applicable

@nisha_deepak - you can use relative date slicer to show the data for last 30,60,90 and so on days, months, years as you like.

NikhilKumar_0-1604238178461.png

 

View solution in original post

3 REPLIES 3
Fowmy
Super User
Super User

@nisha_deepak 

Create a Slicer Table as follows, you can add more rows as necessary and name it Period

 

Fowmy_0-1604238281178.png
Create the following Measure:

ExpiryFlag = 

var _Period = SELECTEDVALUE(Period[Days]) 
var _ExpiryDate = SELECTEDVALUE('DataTable'[Date])
return 

IF( _ExpiryDate >= (TODAY() - _Period) && _ExpiryDate < TODAY() , 1 , 0)  

 

Assing to the Table visual where you want to see the Expiry dates filter by selected Period Range

Fowmy_1-1604238512669.png

________________________

If my answer was helpful, please consider Accept it as the solution to help the other members find it

Click on the Thumbs-Up icon if you like this reply 🙂

YouTube  LinkedIn

 




 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Anonymous
Not applicable

  • Hi @Fowmy  can you share the pbix file it could be helpful to me
Anonymous
Not applicable

@nisha_deepak - you can use relative date slicer to show the data for last 30,60,90 and so on days, months, years as you like.

NikhilKumar_0-1604238178461.png

 

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.