Thread: Sum by date
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
hmsawyer hmsawyer is offline
external usenet poster
 
Posts: 33
Default Sum by date

I found this one in an old post and it is almost what I need:

=SUMIF(A1:A100,"=" & DATE(YEAR(TODAY())-1,MONTH(TODAY()),1),B1:B100)

However, I need to use a rolling 6 months and this formula is using an
entire year. How would I change it? Thanks!

"hmsawyer" wrote:

In column B, I am trying to add up the values in columns E, H, K, etc (every
third column), but ONLY if the corresponding date in columns C (for E), F
(for H), I (for K), etc (every third column) is within 6 months from TODAY.
I can move the data around if the values need to be next to the corresponding
dates, but that will move around some list validations I already have set up,
so I'm trying to avoid it if possible.

I think it is a sum if, but I can't get it to work. Any help is
appreciated. Thank you so much!