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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
Anonymous
Not applicable

Trailing 4 Week calculation help

Hey everyone, 

 

I'm stuck on a calucation I need some help with. 

I have the following date table 

Robinhood_0-1615582608603.png

 and I have average customer satisfaction score by date in another table 

 

I'm trying to look at trailing week, 

Trailing week ending = 'Date'[Date]+(0-'Date'[weekdaynumber])
which seems to be working  corrently
 
and trailing 4 week 
so last weeks numbers + 3 weeks before that
 
I tried the following but it's not working
Trailing 4 week csat =
calculate([Csat %],
DATESINPERIOD ('Date'[Trailing week ending].[Date],LASTDATE ( 'Date'[Trailing week ending].[Date]),-28,DAY))
 
this doesn't seem to give the correct amount however. 
 
anyone have
 
2 REPLIES 2
Anonymous
Not applicable

Hi @Anonymous,

Can you please share some dummy data with a similar data structure and expected results? It should help us clarify your scenario and test to coding formula.

How to Get Your Question Answered Quickly  

Regards,

Xiaoxin Sheng

DataInsights
Super User
Super User

@Anonymous,

 

The post below may be helpful:

 

https://community.powerbi.com/t5/Desktop/Date-Grouping-based-on-MOST-RECENT-dates/m-p/1461638#M610942 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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