OR Function in Excel Tutorial

Excel Tutorial

Introduction

The OR function in Excel checks multiple conditions and returns TRUE if at least one condition is satisfied. It returns FALSE only when all conditions are FALSE.

For example, a company may approve an employee incentive if the employee achieves a high sales target OR receives an excellent performance score. The OR function makes it easy to check such situations.

What Is the OR Function in Excel?

The OR function is a logical function used to test multiple conditions.

  • If at least one condition is TRUE, OR returns TRUE.
  • If all conditions are FALSE, OR returns FALSE.

OR Function Syntax

=OR(logical1, [logical2], ...)

Arguments:

  • logical1: The first condition to check.
  • logical2: The second condition (optional).
  • ...: Additional conditions you want to test.

Practical Examples of OR Function in Excel

Question 1: Check Student Passing Eligibility

Problem Statement: A teacher wants to identify students who have scored at least 80 marks in either Mathematics or Science.

Student Data:

Student NameMathematicsScienceEligibility
Rahul9065
Priya5585
Amit7060
Neha8590

Excel Formula (D2):

=OR(B2>=80,C2>=80)

Expected Result:

Student NameMathematicsScienceEligibility
Rahul9065TRUE
Priya5585TRUE
Amit7060FALSE
Neha8590TRUE

Explanation: Excel checks both subject marks. If either subject has marks of 80 or above, the result is TRUE.

Concept Covered: Checking whether at least one numeric condition is satisfied.

Question 2: Check Employee Incentive Eligibility

Problem Statement: A company offers an incentive if an employee achieves monthly sales of at least ₹2,00,000 OR receives a performance score of 95 or above.

Employee Data:

Employee NameMonthly SalesPerformance ScoreIncentive Eligibility
Rahul25000080
Priya15000096
Amit12000085
Neha22000098

Excel Formula (D2):

=OR(B2>=200000,C2>=95)

Expected Result:

Employee NameMonthly SalesPerformance ScoreIncentive Eligibility
Rahul25000080TRUE
Priya15000096TRUE
Amit12000085FALSE
Neha22000098TRUE

Explanation: Rahul qualifies through sales, while Priya qualifies through her performance score. Neha satisfies both conditions. Amit satisfies neither.

Concept Covered: Checking alternative business eligibility requirements.

Question 3: Check Product Availability

Problem Statement: An online store wants to identify products that are available either in the main warehouse or in the backup warehouse.

Product Data:

ProductMain Warehouse StockBackup Warehouse StockAvailability
Laptop100
Mouse025
Keyboard00
Monitor1510

Excel Formula (D2):

=OR(B2>0,C2>0)

Expected Result:

ProductMain Warehouse StockBackup Warehouse StockAvailability
Laptop100TRUE
Mouse025TRUE
Keyboard00FALSE
Monitor1510TRUE

Explanation: A product is available if either warehouse has stock greater than zero.

Concept Covered: Checking stock availability across multiple locations.

Question 4: Check Employee Department Eligibility

Problem Statement: An organization allows employees from either the IT or HR department to attend a special training program.

Employee Data:

Employee NameDepartmentTraining Eligibility
RahulIT
PriyaHR
AmitSales
NehaFinance

Excel Formula (C2):

=OR(B2="IT",B2="HR")

Expected Result:

Employee NameDepartmentTraining Eligibility
RahulITTRUE
PriyaHRTRUE
AmitSalesFALSE
NehaFinanceFALSE

Explanation: Excel checks whether the department is IT or HR. Either match makes the result TRUE.

Concept Covered: Checking multiple text conditions.

Student Practice Tasks

Task 1: Sales Incentive Eligibility

An employee qualifies for an incentive if monthly sales are at least ₹1,50,000 OR the performance score is 90 or above.

EmployeeMonthly SalesPerformance ScoreEligibility
Aman18000075
Riya12000095
Mohit10000080

Write an OR formula to check eligibility.

Task 2: Product Discount Eligibility

A product qualifies for a discount if its category is either Electronics or Furniture.

ProductCategoryDiscount Eligibility
LaptopElectronics
ChairFurniture
NotebookStationery

Use OR to check the category.

Final Student Challenge: Build an Employee Award Eligibility Sheet

Create a worksheet that checks whether employees qualify for an annual award.

Conditions:

  • Annual Sales must be at least ₹8,00,000 OR
  • Performance Score must be at least 95 OR
  • Experience must be at least 10 years.

Given Data:

Employee NameAnnual SalesPerformance ScoreExperience (Years)Award Status
Rahul900000804
Priya500000973
Amit4000007512
Neha600000855
Karan10000009815

Your Challenge: Use OR with IF to display “Award Approved” if at least one condition is satisfied. Otherwise, display “Not Approved”.

Key Takeaways

  • OR checks multiple conditions simultaneously.
  • At least one TRUE condition makes the result TRUE.
  • OR returns FALSE only when all conditions are FALSE.
  • It supports numeric, text, and date-based conditions.
  • OR can be combined with IF to display custom messages.
  • It is useful for employee eligibility, incentives, product availability, and business decisions.

Frequently Asked Questions (FAQs)

1. What is the OR function in Excel?

The OR function checks multiple conditions and returns TRUE if at least one condition is satisfied.

2. What happens when all conditions are FALSE?

The OR function returns FALSE when every condition is FALSE.

3. Can OR check more than two conditions?

Yes. You can include multiple conditions in one OR formula.

4. What is the difference between AND and OR?

AND returns TRUE only when all conditions are TRUE. OR returns TRUE when at least one condition is TRUE.

5. Can I use OR with text conditions?

Yes. For example, =OR(B2="IT",B2="HR") checks whether a department is IT or HR.

6. Can I combine OR with IF?

Yes. OR can be placed inside IF to display custom messages based on multiple conditions.

7. Does OR return TRUE or FALSE?

Yes. By itself, the OR function returns either TRUE or FALSE.

8. Where is the OR function used in real business situations?

It is useful for incentive eligibility, employee awards, product availability, discount rules, and checking alternative requirements.