SUMIF function - criteria of between two dates. How?
When using the SUMIF function it allows a criteria from one colomn. How do
you right that to be between two dates. |
=SUMIF(DateRange,"="&X2,SumRange)-SUMIF(DateRange,""&Y2,SumRange)
where X2 <= Y2, calculates a total for dates that are between X2 and Y2 inclusive. Frannie21 wrote: When using the SUMIF function it allows a criteria from one colomn. How do you right that to be between two dates. |
one way:
=SUMPRODUCT(--(A1:A100DATE(2005,1,1)), --(A1:A100<TODAY()), B1:B100) See http://www.mcgimpsey.com/excel/doubleneg for an explanation of the "--" In article , Frannie21 wrote: When using the SUMIF function it allows a criteria from one colomn. How do you right that to be between two dates. |
Correction to link:
http://www.mcgimpsey.com/excel/formulae/doubleneg.html -- Bernard V Liengme www.stfx.ca/people/bliengme remove caps from email "JE McGimpsey" wrote in message ... one way: =SUMPRODUCT(--(A1:A100DATE(2005,1,1)), --(A1:A100<TODAY()), B1:B100) See http://www.mcgimpsey.com/excel/doubleneg for an explanation of the "--" In article , Frannie21 wrote: When using the SUMIF function it allows a criteria from one colomn. How do you right that to be between two dates. |
Thanks for the correction - the other will also work if you include the
..html (my browser adds it if necessary). In article , "Bernard Liengme" wrote: Correction to link: http://www.mcgimpsey.com/excel/formulae/doubleneg.html |
All times are GMT +1. The time now is 05:58 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com