# Sum numbers in a column based on week ending filed -5 days

Options
✭✭
edited 01/09/23

I have a Column called Total Overtime Hours and a a column called week ending which has a date in it. I am trying to sum all the overtime hours by the week ending - 7days I'm doing this calculation in the sheet summary tab.

Here is what I have been trying to get to work

=SUMIF([Total OT Hours]:[Total OT Hours], ([Week ending]), <=TODAY(-5))

• Overachievers
Options

Try this formula:

=SUMIF([Week Ending]:[Week Ending], >=TODAY(-5), [Total OT Hours]:[Total OT Hours])

You were on the right track; you just needed to put your range to evaluate (Week Ending column) then the criterion, then the range to actually sum (Total OT Hours column). Also, I changed the less than to greater than, since we want to pull in dates greater than five days ago.

• Overachievers
Options

Try this formula:

=SUMIF([Week Ending]:[Week Ending], >=TODAY(-5), [Total OT Hours]:[Total OT Hours])

You were on the right track; you just needed to put your range to evaluate (Week Ending column) then the criterion, then the range to actually sum (Total OT Hours column). Also, I changed the less than to greater than, since we want to pull in dates greater than five days ago.