Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi All,
Does anyone know how I can set power bi to automatically select the latest date in my data?
Currently, this is my filter:
When April Data becomes available, I want power BI to automatically select the April -21 value.
How can I achieve this without having to manually select the filter, and republish my report every month?
Cheers,
Kev
Solved! Go to Solution.
Hey @BigKev ,
yes, you should add a calculated column in your date table and check there if the row is the latest date.
If yes, then give it a value like "Latest" otherwise not.
Then you can use that column as a slicer. As the report refreshes this column is also getting refreshed.
Hi, @
As far as I’m concerned, there’s no option to set the default value for slicer in Power BI at current, I think that the only way is to create a measure to filter the slicer to always display the latest date, you can try this:
Datediff = DATEDIFF([Date],TODAY(),DAY)
Is latest date =
var _mindate=MINX(FILTER(ALL('Date'),[Date]<TODAY()),[Datediff])
return
IF(MAX('Date'[Datediff])=_mindate,1,0)
And the slicer can always display the latest date.
You can download my test pbix file here
If this result is not what you want, you can go to the Power BI Idea to submit a new idea so that people with the same idea can vote for you. I will also vote for you.
Best Regards,
Community Support Team _Robert Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hey @BigKev ,
yes, you should add a calculated column in your date table and check there if the row is the latest date.
If yes, then give it a value like "Latest" otherwise not.
Then you can use that column as a slicer. As the report refreshes this column is also getting refreshed.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
108 | |
100 | |
78 | |
64 | |
58 |
User | Count |
---|---|
148 | |
111 | |
94 | |
84 | |
67 |