Week over Week Comparison

cmcreynolds

Active Member
Joined
May 21, 2015
Messages
295
I am posting here because I grab my data using Power Query do some simple rates in PowerPivot's data model and report in a PP Pivot table.

So, the report as it stands is dynamic - it pulls directly from Salesforce and spits out this fantastic pivot table with slicers and a timeline.

Now, a CEO has asked me to have a week to week comparison. I thought I had started a grasp on PQ and PP but this request has blown my mind. (I feel this kind of metric is pointless since last week has already happened and we can't change that...but I digress...)

So, I would assume I'd have to "freeze" every week's data, making sure I have the date to tie to a week number (in my calendar table already, thank goodness). But, how do I (or how can I) still utilize the same slicers and timeline? Won't there be a lot of zeroes popping up?

Anyway, and suggestions as to do this with PowerQuery and PowerPivot?
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
Can you paste a bit of sample data?

In general, you are going to have something like...

[NumTransactions] := COUNTROWS(Transactions)
or whatever, Total Sales, etc

[NumTranactions - Prior Week] := CALCULATE([NumTransactions], DATEADD(Calendar[DateKey], -7, day))

[Num Trans - % Change vs Prior Week] := blah, blah... do some division.
 
Upvote 0
So, there's no need for a percent calculation, so the division is out. It's just a count from one week to the next. Then, yes, the subtraction.

Now, the counts I make are based on dates - so, I'm thinking have two tables, one filtered "Past week" (or 7 days or whatever) and the other before that? Using timelines, I guess? Wouldn't I be able to keep it dynamic that way? (In other words, I wouldn't have to freeze data?)
 
Upvote 0
I think I am starting to understand your ask :) Are you saying you don't HAVE last weeks data?
 
Upvote 0

Forum statistics

Threads
1,224,122
Messages
6,176,502
Members
452,733
Latest member
Gao87

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top