ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   sum the current month (https://www.excelbanter.com/excel-worksheet-functions/227235-sum-current-month.html)

tleehh

sum the current month
 
A B
2/9/09 100
3/1/09 200
4/4/09 150
4/19/09 125
4/29/09 75
5/4/09 130
I have a spreadsheet with invoice date and amount. I need a formula that
only sums the current month invoice amount.

Paul C

sum the current month
 
Try this

=SUMPRODUCT(B2:B7,--(MONTH(A2:A7)=MONTH(NOW())))

if you want to sum a particular month change the MONTH(NOW()) to some other
reference.

If you have multiple years expand to this

=SUMPRODUCT(B2:B7,--(MONTH(A2:A7)=MONTH(NOW())),--(YEAR(A2:A7)=YEAR(NOW())))
--
If this helps, please remember to click yes.


"tleehh" wrote:

A B
2/9/09 100
3/1/09 200
4/4/09 150
4/19/09 125
4/29/09 75
5/4/09 130
I have a spreadsheet with invoice date and amount. I need a formula that
only sums the current month invoice amount.


tleehh

sum the current month
 
Thank you. the formula works fine.

"Paul C" wrote:

Try this

=SUMPRODUCT(B2:B7,--(MONTH(A2:A7)=MONTH(NOW())))

if you want to sum a particular month change the MONTH(NOW()) to some other
reference.

If you have multiple years expand to this

=SUMPRODUCT(B2:B7,--(MONTH(A2:A7)=MONTH(NOW())),--(YEAR(A2:A7)=YEAR(NOW())))
--
If this helps, please remember to click yes.


"tleehh" wrote:

A B
2/9/09 100
3/1/09 200
4/4/09 150
4/19/09 125
4/29/09 75
5/4/09 130
I have a spreadsheet with invoice date and amount. I need a formula that
only sums the current month invoice amount.



All times are GMT +1. The time now is 10:13 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com