How to apply a logical OR to an array in Excel

You can’t typically use OR or AND in “array formulas” because, as you have discovered here, they return only a single result (AND is TRUE only if all conditions are TRUE, OR is TRUE is any are TRUE, as you would expect, so in your example you’ll get TRUE as long as at least one of the 6 values is positive).

I’d use something similar to your suggestion, using + in place of OR effectively, although you don’t need the first two *1 because the + co-erces, so this would suffice

=((A1:A3 > 0) + (B1:B3 > 0) >0) *1

although if you have a single column which can be one thing or another then that’s mutually exclusive, surely, so perhaps that needs just

=(A1:A3="A")+(A1:A3="B")

Leave a Comment

tech