Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi
I am new to DAX and have an issue I'm struggling to resolve. In the table below you'll see I have 2 measures, HK Week Commencing and Billable Woerked Hours. I need to be able to display a rolling 12 week position of week commencing and the hours recorded to that week. So as at today, 11th December 2024 I'd need to display data starting from week commencing 23rd September 2024 to week commencing 9th December 2024. Many thanks in advance for any help offered.
Solved! Go to Solution.
Hi @danextian, I managed to solve the solution by adding the week commencing measure into a filter on a matrix and setting the parameters as below. I managed to figure this out before I saw your reply so haven't tested your suggestion but thank you for your speedy response.
Hi @JimKeelan
I dont know exactly how your mode looks like but try this:
rolling 12 weeks =
CALCULATE (
[sum of billable hours],
DATESINPERIOD ( 'table'[hk week], 'table'[hk week], -12 * 7, DAY )
)
Result should be similar to below screenshot
Hi @danextian, I managed to solve the solution by adding the week commencing measure into a filter on a matrix and setting the parameters as below. I managed to figure this out before I saw your reply so haven't tested your suggestion but thank you for your speedy response.
if you want to show the last 12 weeks and not calculate the value for the last 12 weeks starting from the current row week then that is the approach. Just keep in mind that its reference date changes with each passing day.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.