I'm not really sure what your question is in here. If you want to compare dates - check out this old blog post of mine.
If this is a filtering woe then you may want to look into using Action Filters. You can also make the single filter in the top right corner apply to multiple worksheets. You can do this by clicking on it's drop down option within your dashboard and you'll see the option 'apply to worksheets'.
Hope this puts you on the right path. Not sharing your workbook is fine - but it seems rather basic. Why not mock it up using a random dataset?
please see the attached - it is a superstore example - I'll give you the formulas that you can adjust to meet your need
First the parameters are straight forward
this formula determines the individual values by month to include (I used sales)
if DATETRUNC('month',[Order Date])<= DATETRUNC('month',[enter starting month and year]) and
DATETRUNC('month', DATEADD('month',-[number of months to rollup], [enter starting month and year])) then
[Sales] else 0 end
This one rolls them up
if min([Order Date])>
dateadd('month',-[number of months to rollup],[enter starting month and year])
and min([Order Date])<=[enter starting month and year]then
sum([Rolling months to include sales])+PREVIOUS_VALUE((0)) else 0 end
and this forms a Boolean filter that you can use to decide the range to display
here is the result
If this posts assists in resolving the question, please mark it helpful or as the 'correct answer' if it resolves the question. This will help other users find the same answer/resolution. Thank you.