Use COUNTIF with OR condition

MeredithS

New Member
Joined
Sep 23, 2011
Messages
2
Hello, I am stumped.

I have a spreadsheet with three date columns. I want to create a tally that will count each row only once if any of the three columns contains a date greater than 7/1/2011. Here is my formula for tallying just one column:

=COUNTIF('Deduped Lead Contact Data'!H:H,">=07/01/2011")

The only threads I can find talk about adding COUNTIFs, but I don't want to count a row twice if two of the columns contain a date greater than 7/1/2011.

Any insight would be greatly appreciated! Thanks,
Meredith
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
If you're ok adding a helper column to your spreadsheet, you could:

1. Add a formula that tests if your data condition is met for a particular row. For example, if your dates were in columns A - C, you could insert the following formula in column D, and drag down. It will return "Yes" if your date condition is met.

=IF(MAX(A1:C1)>DATE(2011,7,1),"Yes","No")

2. Next, use a COUNTIF formula to count the number of "Yes" values in column D
 
Upvote 0
Hello, I am stumped.

I have a spreadsheet with three date columns. I want to create a tally that will count each row only once if any of the three columns contains a date greater than 7/1/2011. Here is my formula for tallying just one column:

=COUNTIF('Deduped Lead Contact Data'!H:H,">=07/01/2011")

The only threads I can find talk about adding COUNTIFs, but I don't want to count a row twice if two of the columns contain a date greater than 7/1/2011.

Any insight would be greatly appreciated! Thanks,
Meredith
One way...

Book1
ABCDE
212/15/20088/1/20005/3/2005_7/1/2011
39/20/20129/20/20118/19/2013_5
49/29/20029/24/20136/21/2010__
56/15/20099/21/20083/18/2005__
63/9/201312/8/20043/28/2010__
75/1/20002/2/200010/10/2009__
82/20/200412/12/20073/29/2012__
91/19/201411/26/20055/18/2013__
106/29/20113/16/20046/10/2010__
Sheet1

This formula entered in E3:

=SUMPRODUCT(SIGN((A2:A10>E2)+(B2:B10>E2)+(C2:C10>E2)))
 
Upvote 0
Thanks both! Used T. Valko's formula since I don't want to add a helper column and it worked like a charm!! :)
 
Upvote 0

Forum statistics

Threads
1,214,911
Messages
6,122,192
Members
449,072
Latest member
DW Draft

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