IF(OR with an Array formula

  • Thread starter Thread starter Frank Haverkamp
  • Start date Start date
F

Frank Haverkamp

The IF statement does what I want, But the IF(OR statement gives m
values for all including "Frank" who is not wanted. Help...

IF is column 3
IF(OR is column 4

{=IF(A2:A7 = "LEE",B2:B7,"NA")}
{=IF(OR(A2:A7="LEE",A2:A7="Bob"),B2:B7,"NA")}

Lee 1 1 1
Lee 1 1 1
Bob 2 NA 2
Bob 2 NA 2
Frank 3 NA 3
Frank 3 NA 3

Frank Haverkam
 
The IF statement does what I want

What does {=IF(A2:A7 = "LEE",B2:B7,"NA")} produce, which seems to be what
you want?

And, what do you want to get from:

{=IF(OR(A2:A7="LEE",A2:A7="Bob"),B2:B7,"NA")}

as result?
 
Didn't test yours but I use or in sumproduct formulas all the time
=sumproduct((a2:a7={"a","b","c"})*b2:b7)
 

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

Back
Top