Combining Countif formula with an IF(AND formula

willow1985

Well-known Member
Joined
Jul 24, 2019
Messages
886
Office Version
  1. 365
Platform
  1. Windows
I have been using 2 formulas to get the data I need from a spreadsheet and was wondering if there was a way to combine them?

The first formula is on the report itself:

=IF(AND([@[Date Received]]>=GraphData!$B$13,[@[Date Received]]<=GraphData!$B$3),"Yes","No")

in B13 and B3 I have to and From Dates: January 3, 2020 to May 25, 2020 (for example). This formula looks in the Date Received column and flags a "Yes" or a "No" if it falls in between this date range.

On another Sheet I have formula:

COUNTIFS(WOR[[#All],[W/O Number]],"<>",WOR[[#All],[Customer Exclusions]],"<>Exclude"),"")

This counts everything in W/O Number column that is not blank and any item in Customer Exclusions that does not have the word "Exclude"

On this Countif formula I would also like to count any Date Received that falls in between the specified date range above.
Currently I could add one more condition to the CountIf formula to count anything that says "Yes" in the column AM where I have the IF(AND formula But I do not want to do this.

I will be having a lot of conditions similar to this IF(AND one so it would make the spreadsheet a lot smaller if I could somehow combine the 2 formulas...

I hope I am being clear...

I attached a picture of the sheets, hope this helps.

Thank you to anyone who can help! :)
 

Attachments

  • Count if formula.jpg
    Count if formula.jpg
    240.8 KB · Views: 30

Excel Facts

Get help while writing formula
Click the italics "fx" icon to the left of the formula bar to open the Functions Arguments dialog. Help is displayed for each argument.
How about:

=COUNTIFS(WOR[[#All],[W/O Number]],"<>",WOR[[#All],[Customer Exclusions]],"<>Exclude",WOR[[#All],[Date Received]],">="&GraphData!B13,WOR[[#All],[Date Received]],"<="&GraphData!B3)
 
Upvote 0
This appears to be exactly what I am looking for. I never thought to add it like this... Thank you very much!
 
Upvote 0
I'm glad to help you. Thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,377
Messages
6,119,185
Members
448,872
Latest member
lcaw

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