Could anybody tell me how to add values based on dates.

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I want to get the sum of a particular month E.G. 1 Jan 07 to 31 Jan 07 from 6
months data?
 
Assuming there is only January for ONE year then try:

=SUMPRODUCT(--(MONTH(A1:A100)=1)*(B1:B100))

Where A1:A100 are your dates (cells formatted as DATE) and B1:B100 is the
data to be summated.

If there are multiple years:

=SUMPRODUCT(--(MONTH(A1:A100)=1),--(YEAR(A1:A100)=2007)*(B1:B100))


HTH
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top