Count a number of word occurrences based on "Y"

Zoen

New Member
Joined
Dec 17, 2011
Messages
7
Office Version
  1. 2019
Platform
  1. Windows
Hi All You Smarter People Than Me,
I have been trying to work this out, but seem to find examples online only of solutions that are only numbers based.
Currently I have been able to set up my spreadsheet so that it does a basic countif", but what I am having trouble with is adding an extra condition. Only count items with the term"generic" if the column A has a "Y".

I am trying to set the formula up under cell F2. As a summary this is my argument that I want it to provide the answer to:

If cells in A2:A9 have a Y (or happy to write Yes in full), and also have the word "generic" in column C2:C9 then count it towards the number displayed in F2.

Thank you so much in advance
 

Attachments

  • seeking help from Mr Excel members.jpg
    seeking help from Mr Excel members.jpg
    78 KB · Views: 10

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
Things to consider for the future:

I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

MrExcel has a tool called “XL2BB” that lets you post samples of your data that will allow us to copy/paste it to our Excel spreadsheets, so we can work with the same copy of data that you are. Instructions on using this tool can be found here: XL2BB Add-in

Note that there is also a "Test Here” forum on this board. This is a place where you can test using this tool (or any other posting techniques that you want to test) before trying to use those tools in your actual posts.

See if this helps
Excel Formula:
=COUNTIFS(A$2:A$9,"Y",C$2:C$9,D2)
 
Upvote 0
Thanks mate, I will check my account details now. Oddly, I downloaded the zip file for the XL2BB Add in and double clicked it but nothing happened?! That's why I put the picture up! Thank you very much for your time and help, I sincerely appreciate it!
 
Upvote 0
ok great thank you, I will check it out. Just to confirm, that formula worked perfectly, but I am sure you knew it would :)
 
Upvote 0
..that formula worked perfectly, but I am sure you knew it would :)
It is nice to have the result confirmed since it is not uncommon that the OP actually has different data to what helpers have used (why XL2BB is useful) or the problem is not described accurately. ?

In any case I am glad it worked for you. :)
 
Upvote 0

Forum statistics

Threads
1,215,036
Messages
6,122,794
Members
449,095
Latest member
m_smith_solihull

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