Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hi,
I am trying to compare each weeks collection amounts to the previous week. I have the following formula:
Hi @alexjaco ,
Try the measure as below:
Last weeks Collections Measure =
VAR CurrentWeek = SELECTEDVALUE(Collections[Week Number])
Var CurrentYear = SELECTEDVALUE(Collections[Year])
Var MaxWeekNumber = CALCULATE(MAX(Collections[Week Number]),ALL(Collections))
Return
CALCULATE(SUM(Collections[Weekly Collections]),
Filter(ALL(Collections),[State]=MAX([State])&&
IF(CurrentWeek=1,
Collections[Week Number] = MaxWeekNumber && Collections[Year]=CurrentYear-1,
Collections[Week Number] = CurrentWeek-1 && Collections[Year]=CurrentYear)))
If the above doesnt work,pls upload your .pbix file to onedrive business and share the link with us.Do remember to remove the confidential information.
User | Count |
---|---|
98 | |
75 | |
74 | |
49 | |
26 |