0
votes

I am trying to write a formula to populate the cells in this chart where row 2 has numeric months 1-12 and column B:B has years 2017 and 2018. enter image description here

The month and year is stored in a column of dates on another tab in the same workbook. How do I turn this statement into a formula? All the data for this chart is stored on a tab called D.

=SUMIFS(D!$A:$A,<date column>,<year from date column>,<date column>,<month from date column>,<status column>,"Green")
1

1 Answers

0
votes

With SUMIFS you need to Bracket the DATES:

=SUMIFS(D!$A:$A,D!$B:$B,">=" & DATE($B2,C$2,1),D!$B:$B,"<" & DATE($B2,C$2+1,1),D!$C:$C,"Green")