Count occurrences of text within cells - not exact match

bigmonkey712

New Member
Joined
May 1, 2008
Messages
48
Hi,

I have a number of lists with various versions of same items but want to count key parts of text within cell.

For example:

Column A
Back bacon
Smoked bacon
Rindless bacon

I would use countif(A:A,"*bacon*") to return the value 3.

However I want to take this a step further and have a cell where I can type the word bacon and it returns 3 but I could type smoked instead and get 1.

For example:

Column A remains as above but in say B2 i type bacon and in another cell I have the formula as above but instead of bacon it references B2 so I can type anything I want and get a count of that item.

I have tried countif(A:A,"*B2*") and various syntax variants but no luck.

Any ideas?

Many Thanks

S
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes

Forum statistics

Threads
1,224,832
Messages
6,181,231
Members
453,026
Latest member
cknader

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