Forum Discussion
pbr
Apr 04, 2025Copper Contributor
Using formula in SUMIF criteria
I have an excel sheet as below: A B Date Hours 1/1/2025 5 1/2/2025 6 1/3/2025 2 1/4/2025 0 1/5/2025 1 1/6/2025 3 1/7/2025 8 and so on. In another p...
HansVogelaar
Apr 05, 2025MVP
You might create a pivot table based on the range. Add the Date field to the Rows area and the Hours field to the Values area.
Alternatively, using SUMIFS:
D2 contains 1/1/2025, D3 contains 2/1/2025, etc.
The formula in E2 is
=SUMIFS($B$2:$B$366, $A$2:$A$366, ">="&D2, $A$2:$A$366, "<="&EOMONTH(D2, 0))