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
bcharlto
Frequent Visitor

Rolling Max Price Calculations

I'm trying to apply the rolling sum calculations (http://www.powerpivotpro.com/2013/07/moving-averages-sums-etc/) to price, but having difficulty. I'm trying to build a "RegularPrice" field that is based on the max average price for a product sold at store level over the course of 12 weeks (84 days). I have tried the printscreen attached, but you can see, as average price goes down, so does the regular price... Can anyone help me master this one?

 

 

Untitled.png

 

1 ACCEPTED SOLUTION
bcharlto
Frequent Visitor

Maybe this was just a glitch as I'm working with over 2 million rows of data... It looks to be working now. Cheers

View solution in original post

2 REPLIES 2
bcharlto
Frequent Visitor

Maybe this was just a glitch as I'm working with over 2 million rows of data... It looks to be working now. Cheers

bcharlto
Frequent Visitor

The secondary point here is that I want this to be a table I can reference to bring the "RegularPrice" field into my main query. This could be easier with a seperate SQL query, so let me know if you have a better SQL formula that I should use to calculate RegularPrice as defined above... Kind regards,

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.