• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Count no. of days in a range monthwise

vijay.vizzu

Member
Dear All...,

I have a sheet, in a column Y it has some dates, now i just want to create a summary sheet that it should count no of days in a month wise. i have prepared another sheet monthwise, now i just want to extract the no of days monthwise, i tried countif formula, but gives error, the formula is (=COUNTIF(Due,">1-2-12"&"<1-4-12")) it gives error. Kindly help me
 
Hi vijay.vizzu,


Considered using COUNTIFS()? Try This one:


`=COUNTIFS(A1:A80,">=1/2/2012",A1:A80,"<=1/4/2012")


...where Column A contains dates or:


Code:
=SUMPRODUCT((A1:A80>=C1)*(A1:A80<=C2)*1)


...where Column A contains dates and C1 & C2 contains start and end date respectively.


Regards,

Faseeh
 
Dear Faseeh, Thanks for your answer, but this formulas can't work, it can't count the no. of days according to the month in a range.
 
Are you sure vijay.vizzu???

[pre]
Code:
Dates	        Months	Day Count
26-Jul-12	Jan-12	  2
21-Sep-12	Feb-12	  0
1-Mar-12	Mar-12	  2
25-Mar-12	Apr-12	  0
20-Jan-12	May-12	  0
9-Nov-12	Jun-12	  1
17-Oct-12	Jul-12	  2
25-Jan-12	Aug-12	  1
6-Jun-12	Sep-12	  1
12-Dec-12	Oct-12	  1
2-Aug-12	Nov-12	  1
Dec-12	  1[/pre]

...the data is present in between B1:D13, and am using this formula to calculate values in Column D:


=COUNTIFS($B$2:$B$12,">=1/1/2012",$B$2:$B$12,"<=1/31/2012")

..Changing dates for every month? I hope it will work now.


Faseeh
 
@Faseeh

Hi!

When I read the post I didn't realize what did vijay.vizzu meant with "number or days monthwise" and I still don't.

Can you help improving my poor english? Thanks.

Regards!

PS: after your last post I'm more confused.
 
@ Montrey,

:)Read between the lines, SirJB7 told us his birthday!


@ SirJB7,

What else i can say except....
Code:
:P


Faseeh
 
Back
Top