SUMIF USING DATES

R

RayG

HI,

I need to sum a colum of numbers in cells M5:M33 if it is between the dates
1/1/05 and 1/31/05 dates are in cells C5:C33.
In other words in January.

THANKS
 
A

Aladin Akyurek

=SUMIF($M$5:$M$33,">="&A5)-SUMIF($M$5:$M$33,">"&B5)

where A5 houses 1/1/05 and B5 either 1/31/05 or the formula:

=DATE(YEAR(A5),MONTH(A5)+1,0)
 
A

Aladin Akyurek

Correction...

=SUMIF($C$5:$C$33,">="&A5,$M$5:$M$33)-SUMIF($C$5:$C$33,">"&B5,$M$5:$M$33)

where A5 houses 1/1/05 and B5 either 1/31/05 or the formula:

=DATE(YEAR(A5),MONTH(A5)+1,0)
 
Top