#1   Report Post  
rabol
 
Posts: n/a
Default count dates

Hi

How do I count then rows where the date is within a certin month ?

eg:
A B C
1 xxx some text 01-01-2005
2 yyy some text 31-01-2005
3 zzz some text 01-02-2005
4 vvv some text 01-03-2005

6 Number of rows where month is 01 (2)
7 Number of rows where month is 02 (1)
8 Number of rows where month is 03 (1)

Thanks in advance.
Best
Steen


  #2   Report Post  
Roger Govier
 
Posts: n/a
Default

One way would be
=SUMPRODUCT(--(MONTH(C1:C4)=1)) for January

You could put month numbers 1 - 12 in cells D1:D12 then enter in E1
=SUMPRODUCT(--(MONTH($C$1:$C$4)=D1))
then copy down through E2:E12

Change your range of C1:C4 to suit the larger range of data you will
undoubtedly have.

--
Regards
Roger Govier
"rabol" wrote in message
...
Hi

How do I count then rows where the date is within a certin month ?

eg:
A B C
1 xxx some text 01-01-2005
2 yyy some text 31-01-2005
3 zzz some text 01-02-2005
4 vvv some text 01-03-2005

6 Number of rows where month is 01 (2)
7 Number of rows where month is 02 (1)
8 Number of rows where month is 03 (1)

Thanks in advance.
Best
Steen




  #3   Report Post  
Ragdyer
 
Posts: n/a
Default

Try this:

=SUMPRODUCT(--(MONTH(C1:C25)=ROW(A1)))

And copy down, where each row will be the following month.
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------

"rabol" wrote in message
...
Hi

How do I count then rows where the date is within a certin month ?

eg:
A B C
1 xxx some text 01-01-2005
2 yyy some text 31-01-2005
3 zzz some text 01-02-2005
4 vvv some text 01-03-2005

6 Number of rows where month is 01 (2)
7 Number of rows where month is 02 (1)
8 Number of rows where month is 03 (1)

Thanks in advance.
Best
Steen



  #4   Report Post  
Ragdyer
 
Posts: n/a
Default

Sorry, since I suggested copying down, you'll need the absolute references:

=SUMPRODUCT(--(MONTH($C$1:$C$25)=ROW(A1)))
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------

"rabol" wrote in message
...
Hi

How do I count then rows where the date is within a certin month ?

eg:
A B C
1 xxx some text 01-01-2005
2 yyy some text 31-01-2005
3 zzz some text 01-02-2005
4 vvv some text 01-03-2005

6 Number of rows where month is 01 (2)
7 Number of rows where month is 02 (1)
8 Number of rows where month is 03 (1)

Thanks in advance.
Best
Steen



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
count dates in excel skchth Excel Discussion (Misc queries) 6 March 3rd 05 12:35 AM
How do a count dates? Aviator Excel Discussion (Misc queries) 2 January 5th 05 04:17 PM
How do a count dates? Peo Sjoblom Excel Discussion (Misc queries) 0 December 27th 04 05:13 PM
Using Dates in Count functions HWade Excel Worksheet Functions 1 December 6th 04 10:25 PM
Count occurences between dates DJ Dusty Excel Worksheet Functions 3 November 11th 04 12:25 AM


All times are GMT +1. The time now is 02:35 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"