Sumproduct count between dates for specific day
Assuming column A is Area, B is Start and C is End, and that you have
100 rows in Sheet1, and further assume that you have dates in column A
of Sheet2, then try this in B1 of Sheet2:
=SUMPRODUCT(Sheet1!A$1:A$100="Orange")*(Sheet1!B$1 :B$100<=A1)*(Sheet1!C
$1:C$100=A1))
Adjust the ranges to suit, and then copy down.
Hope this helps.
Pete
On May 17, 2:39*pm, Hud67 wrote:
Hello
I have the following excel database
Area * * * * * Start * * * * * End
Orange * * * *15/05/08 * * 18/05/08
Orange * * * *18/05/08 * * 27/05/08
Blue * * * * * * 01/04/08 * * 25/04/08
Blue * * * * * * 02/05/08 * * 17/05/08
Yellow * * * * *28/04/08 * * 17/05/08
etc.
On a separat worksheet i would like to calculate the following for every day
of the year.
01/01/08 * * * How many Orange where active on that day
01/02/08 etc.
I tried it with summproduct but can't figure out the correct formula to
calculate between the start and end date. Thank you very much for your help.
|