Hi,
i'm trying to update a spreadsheet i created at the beginning of this year. the sheet summarises another workbook that records all of the jobs carried out by my company (we repair cranes and excavators).
currently the summary sheet is set up to only treat the workbook as containing data from a single year, but as we creep up to the new year, i need to find a way of getting the summary to pick out data relevant to a specific year.
if you take a look at the example workbook that i have included you'll see that the first sheet summarises data from the second sheet in a few ways. specifically, row 5 contains formulas for calculating the value of jobs closed in certain months. however, the forumla currently adds together all values from all years as long as they are within the particular month. how can i rewrite this formula so that it only adds together the values from a certain month in a certain year?
Hi,
since you're already using the SUMPRODUCT function, simply add another criterion, like
=SUMPRODUCT(--(MONTH(Date_Closed)=MONTH(B1)),--(YEAR(Date_Closed)=YEAR(B1)),Value)
teylyn
Microsoft MVP - Excel
At Excelforum, you can say "Thank you!" by clicking theicon below the post.
Avoid pie charts with more than two data points. Why? See here (pdf, 559 kb). The only acceptable pie chart is here.
thanks, that appears to be exactly it.
i knew it would be simple, but i just couldn't get the syntax right. i was trying too hard to get them to be in the same criteria needlessly.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks