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.
Hello!
I am working on a report in Power BI Desktop. I am looking at data week over week using 'Week End Date' (Monday - Sunday)
On one page of my report, I specifically want to have my visuals show the Last 3 Weeks AND the next 3 weeks - But I need this to be dynamic so as we move forward the selection updates
Example:
TODAY the weeks that will show are -
last 3 weeks --- Week ending 9/20/2020, 9/27/2020, 10/04/2020 AND
next three weeks --- Week ending 10/11/2020, 10/18/2020, 10/25,2020
Then next week, all of those would adjust forward a week.
Does anyone have any suggestions for how to go about this? Is there a way to write a measure, a new column, or table to easily accomplish this?
Solved! Go to Solution.
let's say you have a [date] column in your calendar table.
so the calculated column would be
InRange = if([date]>TODAY()-21 && [date]<TODAY+21,1,0)
or similar.
yes, add a calculated column to your calendar table. Each time your dataset gets refreshed that column will compute/flag the dates in your desired range. Then use that calculated column in a slicer or as a visual/page/report filter.
@lbendlin So what would that calculation look like for creating the column / how do I write that?
Thank you!
let's say you have a [date] column in your calendar table.
so the calculated column would be
InRange = if([date]>TODAY()-21 && [date]<TODAY+21,1,0)
or similar.
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 |
---|---|
105 | |
105 | |
88 | |
73 | |
66 |
User | Count |
---|---|
124 | |
113 | |
98 | |
81 | |
72 |