Forum Discussion
MightyMicrobe
Helper II
6 years agoMeasure for Previous Week Based on Index
Hi all, I have a table with a numeric index indicating Weeks Back from today. I need to create a measure indicating the value of the previous week, based on the index. I can successfully do...
Tahreem24
Super User
6 years ago
If you want it to use in measure so use MAX instead of EARLIER. Because EARLIER is not supported in measure.
MightyMicrobe
Helper II
6 years agoYes, this is the bit that threw me -- I didn't think of using MAX/MIN instead of EARLIER.
My final formula is this:
Total User Previous Period =
CALCULATE([Total Users],
FILTER(ALL('Asset Customer Activity'), 'Asset Customer Activity'[Weeks Back]=MIN('Asset Customer Activity'[Weeks Back])+1))I do have a calendar table, but for this particular query I'm using the index already there (long story).