Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
How to calculate previous week value?
in data source I have [Week Ending] field where field is in numeric date format and having last day of every week value
I also created one field prevWeekEnding in my data model
I am using following formula
=sum( {$<[Week Ending]= ,prevWeekEnding={"$(=Date([Week Ending]-7))"}>} ListUSD])
while I am using this formula ,
without any selection I am getting result 0 and if I select any date from [week Ending ] , I got the result of current date selection value.
Hi check,
I am not following as guessing you must have Week field, then try this?
=sum( {$<[Week Ending]= ,prevWeekEnding={"$(=Date([Week Ending]-7))"}, Week = {'$(Max(Week) - 1)'}>} ListUSD])
Try
prevWeekEnding={"$(=Date(max([Week Ending])-7))"}>}