Counting Dates In A List

  • Thread starter Thread starter SPHARDEN
  • Start date Start date
S

SPHARDEN

Hi,

I have a pretty basic request. I have a worksheet that has 20 columns
on it. 2 columns of information are really causing me problems. Col A
contains dates and Col B contains an "X" to indicate a reference to an
occurrence on a specific date:

A B
12/21/2003 X
1/2/2004
2/1/2004 X

I need to count the number of occurrences according to date ranges,
i.e. how many occurrences between 1/1/2004 and 2/1/2004. It's a fairly
large worksheet and it seems so simple, but I don't know the correct
function to use. Any help would be appreciated. Thanks.
 
Hi
try the following
=SUMPRODUCT((A1:A999>=DATE(2004,1,1))*(A1:A999<=DATE(2004,2,1))*(B1:B99
9="X"))

HTH
Frank
 
SP,

=SUMPRODUCT((A4:A21>=DATEVALUE("1/1/04"))*(A4:A21<DATEVALUE("2/1/04"))*(B4:B
21="X"))

I presume you wanted to include only those rows with the x (or X -- it's not
case-sensitive).
 
Back
Top