Another Blank Cell query

Matt Cook

New Member
Joined
Oct 13, 2022
Messages
14
Office Version
  1. 365
Platform
  1. Windows
Hi

I've got some great info from this forum however I cannot find the answer to my current question, Although I'm sure it's been asked before.

I have a column 'M', containing either, Yes, No or 'blank'

I am using the following COUNTIFS formula to get the info I need but now I need to add the blank cells into the result when searching for a 'Yes.

=COUNTIFS('Job Log'!H:H,">="&A2,'Job Log'!H:H,"<"&A3,'Job Log'!M:M,"Yes",'Job Log'!F:F,"AW7212 Lincoln")

Can somebody help me please?

Thanks
 

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand
trythis ( Just copy and paste your equation and changed "Yes" to "")
Excel Formula:
=COUNTIFS('Job Log'!H:H,">="&A2,'Job Log'!H:H,"<"&A3,'Job Log'!M:M,"Yes",'Job Log'!F:F,"AW7212 Lincoln")+COUNTIFS('Job Log'!H:H,">="&A2,'Job Log'!H:H,"<"&A3,'Job Log'!M:M,"",'Job Log'!F:F,"AW7212 Lincoln")
 
Upvote 0
Solution
Another option
Excel Formula:
=SUM(COUNTIFS('Job Log'!H:H,">"&A2,'Job Log'!H:H,"<"&A3,'Job Log'!F:F,"AW7212 Lincoln",'Job Log'!M:M,{"Yes",""}))
 
Upvote 0
trythis ( Just copy and paste your equation and changed "Yes" to "")
Excel Formula:
=COUNTIFS('Job Log'!H:H,">="&A2,'Job Log'!H:H,"<"&A3,'Job Log'!M:M,"Yes",'Job Log'!F:F,"AW7212 Lincoln")+COUNTIFS('Job Log'!H:H,">="&A2,'Job Log'!H:H,"<"&A3,'Job Log'!M:M,"",'Job Log'!F:F,"AW7212 Lincoln")

This works a treat but only when the first COUNTIFS is looking for the blank cell.

Thanks so much for this, I didn't know that I could add formulas together in that way. I feel you've shown me so much more than just the solution to my query.
 
Upvote 0
Another option
Excel Formula:
=SUM(COUNTIFS('Job Log'!H:H,">"&A2,'Job Log'!H:H,"<"&A3,'Job Log'!F:F,"AW7212 Lincoln",'Job Log'!M:M,{"Yes",""}))

Hi

Thanks so much for this reply.

I couldn't get this formula to work for some reason.
 
Upvote 0
I couldn't get this formula to work for some reason.
I don't know what your data looks like, but here is what I get when I tested it on a mock up (should result in 3 matches to all the criteria)

Book1
FGHIJKLM
1Column FColumn HColumn M
24Yes
35Yes
4AW7212 Lincoln6
57Yes
6AW7212 Lincoln8
7AW7212 Lincoln9Yes
8AW7212 Lincoln10
9AW7212 Lincoln11Yes
1012Yes
Job Log


Book1
ABC
1
25H:H more than this
310H:H less than this
4
53Result of formula
6
Sheet2
Cell Formulas
RangeFormula
A5A5=SUM(COUNTIFS('Job Log'!H:H,">"&A2,'Job Log'!H:H,"<"&A3,'Job Log'!F:F,"AW7212 Lincoln",'Job Log'!M:M,{"Yes",""}))


Did you try copying and pasting the formula into the cell where you wanted the result?
 
Upvote 0
I don't know what your data looks like, but here is what I get when I tested it on a mock up (should result in 3 matches to all the criteria)

Book1
FGHIJKLM
1Column FColumn HColumn M
24Yes
35Yes
4AW7212 Lincoln6
57Yes
6AW7212 Lincoln8
7AW7212 Lincoln9Yes
8AW7212 Lincoln10
9AW7212 Lincoln11Yes
1012Yes
Job Log


Book1
ABC
1
25H:H more than this
310H:H less than this
4
53Result of formula
6
Sheet2
Cell Formulas
RangeFormula
A5A5=SUM(COUNTIFS('Job Log'!H:H,">"&A2,'Job Log'!H:H,"<"&A3,'Job Log'!F:F,"AW7212 Lincoln",'Job Log'!M:M,{"Yes",""}))


Did you try copying and pasting the formula into the cell where you wanted the result?

Hi

Yes, I did copy and paste the formula to where it needed to go. I've always had problems within this COUNTIFS when looking for more than one criteria within a criteria range. (The Yes and blank).

The formula below works, so I'm happy I have this functionality working within my spreadsheet.

=COUNTIFS('Job Log'!H:H,">="&A7,'Job Log'!H:H,"<"&A8,'Job Log'!M:M,"",'Job Log'!D:D,"*AW7212 Lincoln")+COUNTIFS('Job Log'!H:H,">="&A7,'Job Log'!H:H,"<"&A8,'Job Log'!M:M,"Yes",'Job Log'!D:D,"AW7212 Lincoln")

H = a week commencing date


Thank you
 
Upvote 0

Forum statistics

Threads
1,214,642
Messages
6,120,701
Members
448,980
Latest member
CarlosWin

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