Count ifs with date range

Imran Azam

Board Regular
Joined
Mar 15, 2011
Messages
103
HI Guys

i am trying to create a formula where it does a count if the date range condition is matched else bring back blank, below is the data

[TABLE="width: 290"]
<colgroup><col><col><col><col></colgroup><tbody>[TR]
[TD]Name[/TD]
[TD]State[/TD]
[TD][/TD]
[TD]Created On[/TD]
[/TR]
[TR]
[TD]Alex[/TD]
[TD]Qualified[/TD]
[TD][/TD]
[TD="align: right"]30/04/2019[/TD]
[/TR]
[TR]
[TD]Alex[/TD]
[TD]Qualified[/TD]
[TD][/TD]
[TD="align: right"]01/05/2019[/TD]
[/TR]
[TR]
[TD]Alex[/TD]
[TD]Qualified[/TD]
[TD][/TD]
[TD="align: right"]28/05/2019[/TD]
[/TR]
[TR]
[TD]Alex[/TD]
[TD]Qualified[/TD]
[TD][/TD]
[TD="align: right"]03/03/2019[/TD]
[/TR]
[TR]
[TD]James[/TD]
[TD="colspan: 2"]Not Qualified[/TD]
[TD="align: right"]04/05/2019[/TD]
[/TR]
[TR]
[TD]James[/TD]
[TD]Qualified[/TD]
[TD][/TD]
[TD="align: right"]05/05/2019[/TD]
[/TR]
[TR]
[TD]James[/TD]
[TD]Qualified[/TD]
[TD][/TD]
[TD="align: right"]06/05/2019[/TD]
[/TR]
[TR]
[TD]James[/TD]
[TD="colspan: 2"]Not Qualified[/TD]
[TD="align: right"]07/05/2019[/TD]
[/TR]
[TR]
[TD]James[/TD]
[TD="colspan: 2"]Not Qualified[/TD]
[TD="align: right"]08/05/2019
[/TD]
[/TR]
</tbody>[/TABLE]


the logic i am trying to use is if Name is Alex and State = Qualified and created on is between 01/05/2019 and 30/05/2019( i just want may data) then return the count of the name, the formula i have done is below but it isn't working

=COUNTIFS(Name,"Alex",state,"Qualified",Created on,">=01/05/2019",D:D,Created on,"<=30/5/2019)/COUNTIF(Name,"Alex")

can anyone help with this?

thanks
 
thanks what if i want the date range from 01/01.2019 to 01/05/2018, can this be done using same formula?
It depends on whether or not you want to include the May 1 date in your count. If so, then you will need to do something like Marcelo should to include that date.
If not, you can use the formula that Repush just posted (which will NOT include the May 1 dates).
 
Upvote 0

Excel Facts

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)

Forum statistics

Threads
1,223,907
Messages
6,175,301
Members
452,633
Latest member
DougMo

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top