How to calculate the weekly amount (the sum of the last 7 lines printed on the 7th line) based on daily values, the same question for monthly (based on weekly or daily). I tried some formulas, but they all failed.
(first column is a date column, not an image)
PS sorry for the "too localized" and "not constructive", I just do not know how to set it differently.
In the week column, you can add a formula, for example =IF(WEEKDAY(A8)=7,sum(B2:B8),"")(to put the amount of the week on Sundays.
=IF(WEEKDAY(A8)=7,sum(B2:B8),"")
For the month column: =IF(MONTH(A2)<>MONTH(A2+1),SUM(B$2:B2)-SUMIF(A$2:A2,"<"&DATE(YEAR(A2),MONTH(A2),1),B$2:B2),"")
=IF(MONTH(A2)<>MONTH(A2+1),SUM(B$2:B2)-SUMIF(A$2:A2,"<"&DATE(YEAR(A2),MONTH(A2),1),B$2:B2),"")
=IF(IFERROR(WEEKNUM(A2)=WEEKNUM(A1), FALSE), "",SUM(B2:B8))
=IF(IFERROR(MONTH(A2)=MONTH(A1), FALSE), "",SUMIF(A2:A33, "<"&DATE(YEAR(A2),MONTH(A2)+1,1), B2:B33))
. / (, -, )
: sumif 31 . , 31 . 31 , , , 28,29 30 . , WILL .