How to use IF AND and wildcard for text ending?

S

Susana

Hello,
I'm trying to get a cell to show a message if two other cells contain some
specific text:
ex.
=IF(AND(A3="RRA05*";C3="KRF");"Tipo 4";"Tipo 1")

but I'm having trouble with the wildcard *

I have already tried ...A3="RRA05?????"... as this article code is always 10
digit long, but it also doesn't work

Should I format the cells in any specific way (as "text" or something else)
so it will work?

Thank you very much in advance, for all the help provided

Susana
 
P

Paul C

Try
=IF(AND(LEFT(A3,5)="RRA05",C3="KRF"),"Tipo 4","Tipo 1")

or if the RRA05 is not always at the start


=IF(AND(ISERROR(FIND("RRA05",A3))=FALSE,C3="KRF"),"Tipo 4","Tipo 1")
 
G

Gary Brown

=IF(IF(ISERROR(SEARCH("RRA05",A3)),0,1)+IF(ISERROR(SEARCH("KRF",C3)),0,1)=2,"Tipo 4","Tipo 1")

FYI,
'Search' will look disregard upper/lower case.
'Find' will consider case.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top