The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi Developers,
I'm a newbie,
My requirement is:
1) In my report I'm using Date Slicer, by default the Date slicer should show Latest Date when it get refreshed and it should also show all the dates in the table.
Note: Without Bookmark
2) I have a trend chart by default it should show data for past 7 days e.g if the slicer is selected for the Today's dates (above slicer requirement has relation with it) obviously it'll show data for only 1 date instead it should show for the last 7 days how to do it.
Please let me know the steps or youtube tutorials
Solved! Go to Solution.
Hi @cmkp2675
Sorry for the late response.
There isn’t a way to have a “between” slicer default itself to the latest date dynamically. Power BI doesn’t support that out-of-the-box without bookmarks. Instead, here’s a reliable pattern that meets both of your needs:
Please do follow the below steps that will resolve your issue:
Swap your “Between” slicer for a Relative Date slicer set to “This 1 Days,” so it always defaults to today’s date
In Format → Edit interactions, disable the slicer’s filter on your table visual so it continues to show every date row
Create a measure that ignores any slicer and always sums the last 7 days, for example:
-------------------------------------------------------------------------------
LoadDurationLast7Days =
CALCULATE(
SUM('etl_pipeline_audit'[pipeline_run_duration_mins]),
DATESINPERIOD(
'Date_Table'[Date],
MAX('Date_Table'[Date]),
-6,
DAY
)
)
-------------------------------------------------------------------------------
If needed, use Edit interactions to turn off slicer filtering on the trend chart so it consistently displays those seven days.
If the above information is helpful, please give us Kudos and mark the response as Accepted as solution.
Best Regards,
Community Support Team _ C Srikanth.
Hi @cmkp2675
It's been a while since I heard back from you and I wanted to follow up. Have you had a chance to try the solutions that have been offered?
If the issue has been resolved, can you mark the post as resolved? If you're still experiencing challenges, please feel free to let us know and we'll be happy to continue to help!
Looking forward to your reply!
Best Regards,
Community Support Team _ C Srikanth.
Hi @cmkp2675
I wanted to follow up since I haven't heard from you in a while. Have you had a chance to try the suggested solutions?
If your issue is resolved, please consider marking the post as solved. However, if you're still facing challenges, feel free to share the details, and we'll be happy to assist you further.
Looking forward to your response!
Best Regards,
Community Support Team _ C Srikanth.
Hi @cmkp2675
We haven't heard from you since last response and just wanted to check whether the solution provided has worked for you. If yes, please Accept as Solution to help others benefit in the community.
Thank you.
If the above information is helpful, please give us Kudos and mark the response as Accepted as solution.
Best Regards,
Community Support Team _ C Srikanth.
Hi @cmkp2675
Sorry for the late response.
There isn’t a way to have a “between” slicer default itself to the latest date dynamically. Power BI doesn’t support that out-of-the-box without bookmarks. Instead, here’s a reliable pattern that meets both of your needs:
Please do follow the below steps that will resolve your issue:
Swap your “Between” slicer for a Relative Date slicer set to “This 1 Days,” so it always defaults to today’s date
In Format → Edit interactions, disable the slicer’s filter on your table visual so it continues to show every date row
Create a measure that ignores any slicer and always sums the last 7 days, for example:
-------------------------------------------------------------------------------
LoadDurationLast7Days =
CALCULATE(
SUM('etl_pipeline_audit'[pipeline_run_duration_mins]),
DATESINPERIOD(
'Date_Table'[Date],
MAX('Date_Table'[Date]),
-6,
DAY
)
)
-------------------------------------------------------------------------------
If needed, use Edit interactions to turn off slicer filtering on the trend chart so it consistently displays those seven days.
If the above information is helpful, please give us Kudos and mark the response as Accepted as solution.
Best Regards,
Community Support Team _ C Srikanth.
Hi @cmkp2675
Since your X-axis is Date and Y-axis is Load Duration (Min), and you want the chart to always show the last 7 days regardless of slicer selection, you need to:
Make sure the Date slicer is a relative date slicer set to “in the last 7 days.” This makes the slicer dynamically update with the latest dates.
If you must keep a regular slicer, then create a measure that ignores the slicer filter on Date and forces the last 7 days data. For example:
LoadDurationLast7Days =
CALCULATE(
SUM('Table'[Load Duration]),
FILTER(
ALL('Date'[Date]),
'Date'[Date] >= TODAY() - 7 && 'Date'[Date] <= TODAY()
)
)
Use this measure on the Y-axis instead of the original measure.
On the visual’s X-axis, use the Date column but make sure to turn off any slicer or page level filter on the Date column, or if you want to keep slicer for other visuals, use the measure that ignores the slicer filter as shown.
If this still doesn’t work, please share the exact DAX measure and slicer setup you are using so I can help debug further.
If the above information is helpful, please give us Kudos and mark the response as Accepted as solution.
Best Regards,
Community Support Team _ C Srikanth.
Hi @v-csrikanth
Thank you for your response.
But still not working no filters applied except Dropdown SLICER (it's mandatory) to filter other visuals.
DAX:
Hi @cmkp2675
If the above information is helpful, please give us Kudos and mark the response as Accepted as solution.
Best Regards,
Community Support Team _ C Srikanth.