Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I need a formula to search column B for the content in column A.I want a true/false answer

A1:/EV-16-4014 B1:/HA4/EV-16-4014 true

A2:/EV-16-4021B B2:/HA3/EV-16-4021B true

A3:/EV-16-4028 B3:/STUDY-2500/10-ESD false

Can somone help me?

share|improve this question
add comment

2 Answers

Try this:

=IF(ISERROR(VLOOKUP($A1,$B$1:$B$[EndOfTableRange],1,FALSE),FALSE,TRUE)

I would then put this in column C. It searches for the value in the adjacent cell in A, anywhere in the range of cells in B, if it finds something then there is no error so it ISERROR returns FALSE, and the IF statement returns TRUE, otherwise it returns FALSE.

share|improve this answer
add comment

At first glance I would suggest the formula

=COUNTIF(B:B,A1)>0

as that will perform better and is also more concise. It will return a TRUE if it finds one or more exact matches.

Looking at your data however, it looks like you want to know if the value of cell A1 was contained in the value of cell B1 (and so on). For that matter this formula should do:

=NOT(ISERROR(FIND(A1,B1,1)))
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.