Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
re9diuehi8e0
New Member

Power Bi Paginated Report: How to show the Week number for Previous Week?

Good Morning,

 

I have an incredible simple question that frustrating me. I need title of the report to show the week number of the previous week. As the report is showing data for a week behind.

 

The expression I am currently using is:

 

=DatePart(DateInterval.WeekOfYear,today())

 

Which obviously show the current week but no matter how I change the TODAY() it doesn't work

1 ACCEPTED SOLUTION
bradsy
Employee
Employee

he first week of the year could be tricky, this should work:

 

=IIF(DatePart(DateInterval.WeekOfYear,Today()) - 1 = 0, 52, DatePart(DateInterval.WeekOfYear,Today()) - 1)

View solution in original post

2 REPLIES 2
bradsy
Employee
Employee

he first week of the year could be tricky, this should work:

 

=IIF(DatePart(DateInterval.WeekOfYear,Today()) - 1 = 0, 52, DatePart(DateInterval.WeekOfYear,Today()) - 1)

This worked! Thank you very much

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.