Peaceful_Warrior
Peaceful_Warrior

Reputation: 70

Excel function to search for a string of letters in a column

I've a column with cells containing the word "Google" and "Google.com" as well. If I search for the keyword "Google" using the formula =COUNTIF(B1:B940,"Google") it doesn't count the "Google.com" ones. Which formula can I use which gives me the count for both.

Upvotes: 1

Views: 269

Answers (2)

paxdiablo
paxdiablo

Reputation: 881463

Well, for your specific case, it might be preferable to just do:

=COUNTIF(B1:B940,"Google")+COUNTIF(B1:B940,"Google.com")

For something more complex, countif allows wildcards:

=COUNTIF(B1:B940,"Google*")

but that may pick up stuff you're not interested in, such as Google ate my homework.

Upvotes: 1

Werner
Werner

Reputation: 15065

You can use the wildcard * in your search term, like "Google*":

enter image description here

Other wildcards like ? can also be used if you know the length of the wildcard.

Upvotes: 1

Related Questions