ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Countif question (https://www.excelbanter.com/excel-worksheet-functions/231063-countif-question.html)

Patrick C. Simonds

Countif question
 
I need to be able to check the range D19:AB19 for any occurrence of the
phrase On Call. That is easy enough with the formula below so my problem is
it could be entered as just On Call or On Call #1 or On Call #4 ect.

So what I need is something that will count the occurance of On Call or any
phrase containing On Call.

=COUNTIF(D19:AB19,"On Call")


Per Jessen

Countif question
 
Hi

You have to use a wildcard.

=COUNTIF(D19:AB19,"On Call*")

Regards,
Per

"Patrick C. Simonds" skrev i meddelelsen
...
I need to be able to check the range D19:AB19 for any occurrence of the
phrase On Call. That is easy enough with the formula below so my problem is
it could be entered as just On Call or On Call #1 or On Call #4 ect.

So what I need is something that will count the occurance of On Call or
any phrase containing On Call.

=COUNTIF(D19:AB19,"On Call")



Bernard Liengme[_3_]

Countif question
 
Use =COUNTIF(D19:AB19,"On Call*")
where the asterisk (*) is a wild card meaning "and anything else after On
Call"
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email

"Patrick C. Simonds" wrote in message
...
I need to be able to check the range D19:AB19 for any occurrence of the
phrase On Call. That is easy enough with the formula below so my problem is
it could be entered as just On Call or On Call #1 or On Call #4 ect.

So what I need is something that will count the occurance of On Call or
any phrase containing On Call.

=COUNTIF(D19:AB19,"On Call")




pub

Countif question
 
"Patrick C. Simonds" wrote in
:

I need to be able to check the range D19:AB19 for any occurrence of
the phrase On Call. That is easy enough with the formula below so my
problem is it could be entered as just On Call or On Call #1 or On
Call #4 ect.

So what I need is something that will count the occurance of On Call
or any phrase containing On Call.

=COUNTIF(D19:AB19,"On Call")



you should be able to use the wildcard *

try this
=COUNTIF(D19:AB19,"On Call*")

Domenic[_2_]

Countif question
 
In article ,
"Patrick C. Simonds" wrote:

I need to be able to check the range D19:AB19 for any occurrence of the
phrase On Call. That is easy enough with the formula below so my problem is
it could be entered as just On Call or On Call #1 or On Call #4 ect.

So what I need is something that will count the occurance of On Call or any
phrase containing On Call.

=COUNTIF(D19:AB19,"On Call")



If 'On Call' occurs at the beginning of the text string, try...

=COUNTIF(D19:AB19,"On Call*")

or

=COUNTIF(D19:AB19,A2&"*")

....where A2 contains 'On Call'. If 'On Call' can occur anywhere within
the text string, try...

=COUNTIF(D19:AB19,"*On Call*")

or

=COUNTIF(D19:AB19,"*"&A2&"*")

....where, again, A2 contains 'On Call'.

--
Domenic
http://www.xl-central.com


All times are GMT +1. The time now is 05:11 PM.

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