Related Function:

The OR function tests a number of supplied conditions. Returns TRUE if any of the conditions evaluate to TRUE; returns FALSE if all of the conditions evaluate to FALSE.

 

Syntax

=OR(logical_test-1,[logical_test-2], … )

Note: If the logical_tests return numbers, instead of logical values, zero is treated as the logical value FALSE and all non-zero numbers are treated as the logical value TRUE.

Arguments

Argument Description
logical_test-1 The first condition that you want to test that can evaluate to either TRUE or FALSE
[logical_test-2] … Optional. Additional conditions that you want to test that can evaluate to either TRUE or FALSE
  • If an array or reference argument contains text or empty cells, those values are ignored
  • You can use an OR array formula to see if a value occurs in an array. To enter an array formula, press CTRL+SHIFT+ENTER

Examples

  A B D C
1 Data      
2        
3 Formula Result Notes
4 =OR(TRUE) TRUE One argument is true
5 =OR(1+1=1,2+2=5) FALSE All arguments evaluate to FALSE
6 =OR(TRUE,FALSE,TRUE) TRUE At least one argument evaluates to TRUE
7 =OR(A1=””,B1=””) TRUE B2 is an empty cell, one argument is TRUE
8 =IF(OR(1+1=1,2+2=5,A1<>””),”true text”,”false text”) true text At least one argument (A1<>””) evaluates TRUE

Common Function Error(s)

Problem What went wrong
#VALUE! Occurs if the specified range contains no logical values