Counting dates

  • Thread starter Thread starter wendy
  • Start date Start date
W

wendy

Trying to do something really simple here but cant seem to get it righ


have a list of dates

12/01/2009
13/01/2009
12/01/2009
13/02/2009
14/01/2009


obviously the list is longer!

all i want to be able to do is count the number of entries for eg. jan

have tried =countif(A1:A5,"=**/01/2009")

but this just returns an error message

can anyone help prob dead simple if you know how!
thanks
wen
 
all i want to be able to do is count the
number of entries for eg. jan

For January of *any* year or will your dates all be within the same year?

For January of *any* year:

=SUMPRODUCT(--(MONTH(A1:A100)=1)

Note that if there are any empty cells in the range they will be evaluated
as month 1 (January). To account for that:

=SUMPRODUCT(--(MONTH(A1:A100)=1),--(A1:A100<>""))

To count for a specific year:

=SUMPRODUCT(--(MONTH(A1:A100)=1),--(YEAR(A1:A100)=2009))
 
T. Valko;3241754 said:
all i want to be able to do is count the-
number of entries for eg. jan-

For January of *any* year or will your dates all be within the sam
year?

For January of *any* year:

=SUMPRODUCT(--(MONTH(A1:A100)=1)

Note that if there are any empty cells in the range they will b
evaluated
as month 1 (January). To account for that:

=SUMPRODUCT(--(MONTH(A1:A100)=1),--(A1:A100""))

To count for a specific year:

=SUMPRODUCT(--(MONTH(A1:A100)=1),--(YEAR(A1:A100)=2009))


--
Biff
Microsoft Excel MVP


"wendy" (e-mail address removed) wrote in message

Trying to do something really simple here but cant seem to get i
right


have a list of dates

12/01/2009
13/01/2009
12/01/2009
13/02/2009
14/01/2009


obviously the list is longer!

all i want to be able to do is count the number of entries for eg
jan

have tried =countif(A1:A5,"=**/01/2009")

but this just returns an error message

can anyone help prob dead simple if you know how!
thanks
wend
perfect thank you so much
 
Back
Top