ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   search for text "beginning with" "containing" wildcards (https://www.excelbanter.com/excel-worksheet-functions/253225-search-text-beginning-containing-wildcards.html)

david h

search for text "beginning with" "containing" wildcards
 
I have numerous occasions where functions (like countif) need to report on
cells containing text strings or starts with text strings.

In various database utilities there are wildcards which provide this
functionality, but what about in Excel, do any wildcards work ?

Dave Peterson

search for text "beginning with" "containing" wildcards
 
In some functions, they do:

=countif(a1:a10,"text*")
=countif(a1:a10,"*text")
=countif(a1:a10,"*text*")

And you can use
"*" & x99 & "*"
as the second argument.

If you want to look for an asterisk character, use ~* in the string.
If you want to look for a question mark, use ~? in the string.
If you want to look for a tilde (~), use ~~ in the string.




David H wrote:

I have numerous occasions where functions (like countif) need to report on
cells containing text strings or starts with text strings.

In various database utilities there are wildcards which provide this
functionality, but what about in Excel, do any wildcards work ?


--

Dave Peterson


All times are GMT +1. The time now is 12:51 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com