A
Attila Fust
I am trying to sum data if a date range matches (year and
month only). Here is the example:
Table1
5/15/00 5/16/00 6/17/00 (NAME=DATES1)
5 5 5 (NAME=SALES)
Table2
5/1/00 6/1/00 7/1/00 (NAME=DATES2)
<sum1> <sum2> <sum3>
In Table2 I want to create a formula to sum the data by
month under the appropriate month (ie. in sum1, sum2 and
sum3). Using the named ranges above I created the
following formula:
=SUMPRODUCT(--(MONTH(DATES1)=MONTH(DATES2)),--(YEAR(DATES1)
=YEAR(DATES2)),SALES)
This formula does not work but the results I would like is
to have in Table 2 are - $10 under 5/1/00, $5 under
6/1/00 and $0 under 7/1/00. Unfortunately my formula does
not work.
Am I on the right track or should I do something else?
Thanks in advance.
Attila Fust
month only). Here is the example:
Table1
5/15/00 5/16/00 6/17/00 (NAME=DATES1)
5 5 5 (NAME=SALES)
Table2
5/1/00 6/1/00 7/1/00 (NAME=DATES2)
<sum1> <sum2> <sum3>
In Table2 I want to create a formula to sum the data by
month under the appropriate month (ie. in sum1, sum2 and
sum3). Using the named ranges above I created the
following formula:
=SUMPRODUCT(--(MONTH(DATES1)=MONTH(DATES2)),--(YEAR(DATES1)
=YEAR(DATES2)),SALES)
This formula does not work but the results I would like is
to have in Table 2 are - $10 under 5/1/00, $5 under
6/1/00 and $0 under 7/1/00. Unfortunately my formula does
not work.
Am I on the right track or should I do something else?
Thanks in advance.
Attila Fust