Forum Discussion
Filter a report using query string for relative dates
- 6 years ago
Hi Anonymous ,
How about to use filter on this visual?
Days = VAR x = CALCULATE( LASTDATE('Table'[Date]), ALL('Table'[Date]) ) RETURN DATEDIFF( MAX('Table'[Date]), x, DAY )Even if your data is updated daily, only the last 30 days will be displayed.
If you want to display longer data, you need to modify the filter.
Best regards,
Lionel ChenIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
I see! But you have made buckets in your time. Mine is a date slicer like below. I want to provide 30-day dynamic filter.
Yes, I made buckets and that's what makes it dynamic.
Whenever the report is refreshed the calculated column is recalculated potentially moving the current quarter.
You'll need to do something similar and switch from the Date slicer to a 'regular' slicer to handle the dynamism.
- Anonymous6 years agoNot applicable
But buckets don't serve our business purpose. We need to drill down to the date level in historical data too.
If I have both bucket and date filter, the User Experience is really bad.
Since date selector shows different dates and the bucket filter shows something else. 😞