#1   Report Post  
jpjsmith
 
Posts: n/a
Default if(A10="test"1,0)

In a conditional statement is there any way to use some sort of "Like"
instead of just =, !=, ? I have a column with values similar to
value=10, value=12, value=50. Is there any way to count the number of
occurrences of "value"? The =if(A1="value",1,0) doesn't work because
its looking at the entire cell value, what I'd like is some sort of
=if(A10 LIKE "value,1,0) is this possible?

  #2   Report Post  
Dave Peterson
 
Posts: n/a
Default

=IF(ISNUMBER(SEARCH("value",A1)),1,0)
or
=if(countif(a1,"*value*")0,1,0)

You could also just use:
=countif(a1:a10,"*value*")

To look for value in a1:a10

or maybe...
=countif(a1:a10,"value*")
to count those cells that Start with "value".




jpjsmith wrote:

In a conditional statement is there any way to use some sort of "Like"
instead of just =, !=, ? I have a column with values similar to
value=10, value=12, value=50. Is there any way to count the number of
occurrences of "value"? The =if(A1="value",1,0) doesn't work because
its looking at the entire cell value, what I'd like is some sort of
=if(A10 LIKE "value,1,0) is this possible?


--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 06:37 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"