Is there a way to use a formula in the sumifs function criteria range?
For example, say there column A has dates and column B has sales figures. If I wanted to find all the sales in December 2011, I would normally create two extra columns C =year(A1) and D =month(A1).
Then my formula would be sumifs(B1:B10,C1:C10,2011,D1:D10,12). It would obviously be ideal to not have to create extra columns and be able to do:
sumifs(B1:B10,year(A1:A10),2011,month(A1:A10),12)
That doesn't work and I can't seem to use array formulas (the ones with the {}) to do it within the function either. Anyone know a way?
For example, say there column A has dates and column B has sales figures. If I wanted to find all the sales in December 2011, I would normally create two extra columns C =year(A1) and D =month(A1).
Then my formula would be sumifs(B1:B10,C1:C10,2011,D1:D10,12). It would obviously be ideal to not have to create extra columns and be able to do:
sumifs(B1:B10,year(A1:A10),2011,month(A1:A10),12)
That doesn't work and I can't seem to use array formulas (the ones with the {}) to do it within the function either. Anyone know a way?