Is not greater than excel

The IF function allows you to make a logical comparison between a value and what you expect by testing for a condition and returning a result if that condition is True or False.

  • =IF(Something is True, then do something, otherwise do something else)

But what if you need to test multiple conditions, where let’s say all conditions need to be True or False (AND), or only one condition needs to be True or False (OR), or if you want to check if a condition does NOT meet your criteria? All 3 functions can be used on their own, but it’s much more common to see them paired with IF functions.

Use the IF function along with AND, OR and NOT to perform multiple evaluations if conditions are True or False.

Syntax

  • IF(AND()) — IF(AND(logical1, [logical2], …), value_if_true, [value_if_false]))

  • IF(OR()) — IF(OR(logical1, [logical2], …), value_if_true, [value_if_false]))

  • IF(NOT()) — IF(NOT(logical1), value_if_true, [value_if_false]))

Argument name

Description

logical_test (required)

The condition you want to test.

value_if_true (required)

The value that you want returned if the result of logical_test is TRUE.

value_if_false (optional)

The value that you want returned if the result of logical_test is FALSE.

Here are overviews of how to structure AND, OR and NOT functions individually. When you combine each one of them with an IF statement, they read like this:

  • AND – =IF(AND(Something is True, Something else is True), Value if True, Value if False)

  • OR – =IF(OR(Something is True, Something else is True), Value if True, Value if False)

  • NOT – =IF(NOT(Something is True), Value if True, Value if False)

Examples

Following are examples of some common nested IF(AND()), IF(OR()) and IF(NOT()) statements. The AND and OR functions can support up to 255 individual conditions, but it’s not good practice to use more than a few because complex, nested formulas can get very difficult to build, test and maintain. The NOT function only takes one condition.

Examples of using IF with AND, OR and NOT to evaluate numeric values and text

Here are the formulas spelled out according to their logic:

Formula

Description

=IF(AND(A2>0,B2<100),TRUE, FALSE)

IF A2 (25) is greater than 0, AND B2 (75) is less than 100, then return TRUE, otherwise return FALSE. In this case both conditions are true, so TRUE is returned.

=IF(AND(A3=»Red»,B3=»Green»),TRUE,FALSE)

If A3 (“Blue”) = “Red”, AND B3 (“Green”) equals “Green” then return TRUE, otherwise return FALSE. In this case only the first condition is true, so FALSE is returned.

=IF(OR(A4>0,B4<50),TRUE, FALSE)

IF A4 (25) is greater than 0, OR B4 (75) is less than 50, then return TRUE, otherwise return FALSE. In this case, only the first condition is TRUE, but since OR only requires one argument to be true the formula returns TRUE.

=IF(OR(A5=»Red»,B5=»Green»),TRUE,FALSE)

IF A5 (“Blue”) equals “Red”, OR B5 (“Green”) equals “Green” then return TRUE, otherwise return FALSE. In this case, the second argument is True, so the formula returns TRUE.

=IF(NOT(A6>50),TRUE,FALSE)

IF A6 (25) is NOT greater than 50, then return TRUE, otherwise return FALSE. In this case 25 is not greater than 50, so the formula returns TRUE.

=IF(NOT(A7=»Red»),TRUE,FALSE)

IF A7 (“Blue”) is NOT equal to “Red”, then return TRUE, otherwise return FALSE.

Note that all of the examples have a closing parenthesis after their respective conditions are entered. The remaining True/False arguments are then left as part of the outer IF statement. You can also substitute Text or Numeric values for the TRUE/FALSE values to be returned in the examples.

Here are some examples of using AND, OR and NOT to evaluate dates.

Examples of using IF with AND, OR and NOT to evaluate dates

Here are the formulas spelled out according to their logic:

Formula

Description

=IF(A2>B2,TRUE,FALSE)

IF A2 is greater than B2, return TRUE, otherwise return FALSE. 03/12/14 is greater than 01/01/14, so the formula returns TRUE.

=IF(AND(A3>B2,A3<C2),TRUE,FALSE)

IF A3 is greater than B2 AND A3 is less than C2, return TRUE, otherwise return FALSE. In this case both arguments are true, so the formula returns TRUE.

=IF(OR(A4>B2,A4<B2+60),TRUE,FALSE)

IF A4 is greater than B2 OR A4 is less than B2 + 60, return TRUE, otherwise return FALSE. In this case the first argument is true, but the second is false. Since OR only needs one of the arguments to be true, the formula returns TRUE. If you use the Evaluate Formula Wizard from the Formula tab you’ll see how Excel evaluates the formula.

=IF(NOT(A5>B2),TRUE,FALSE)

IF A5 is not greater than B2, then return TRUE, otherwise return FALSE. In this case, A5 is greater than B2, so the formula returns FALSE.

Example of the Evaluate Formula Wizard

Using AND, OR and NOT with Conditional Formatting

You can also use AND, OR and NOT to set Conditional Formatting criteria with the formula option. When you do this you can omit the IF function and use AND, OR and NOT on their own.

From the Home tab, click Conditional Formatting > New Rule. Next, select the “Use a formula to determine which cells to format” option, enter your formula and apply the format of your choice.

Conditional Formatting > Edit Rule dialog showing the Formula method

Using the earlier Dates example, here is what the formulas would be.

Example of using AND, OR and NOT as Conditional Formatting tests

Formula

Description

=A2>B2

If A2 is greater than B2, format the cell, otherwise do nothing.

=AND(A3>B2,A3<C2)

If A3 is greater than B2 AND A3 is less than C2, format the cell, otherwise do nothing.

=OR(A4>B2,A4<B2+60)

If A4 is greater than B2 OR A4 is less than B2 plus 60 (days), then format the cell, otherwise do nothing.

=NOT(A5>B2)

If A5 is NOT greater than B2, format the cell, otherwise do nothing. In this case A5 is greater than B2, so the result will return FALSE. If you were to change the formula to =NOT(B2>A5) it would return TRUE and the cell would be formatted.

Note: A common error is to enter your formula into Conditional Formatting without the equals sign (=). If you do this you’ll see that the Conditional Formatting dialog will add the equals sign and quotes to the formula — =»OR(A4>B2,A4<B2+60)», so you’ll need to remove the quotes before the formula will respond properly.

Need more help?

Connect with an expert. Learn from live instructors.​​​​​​​

See also

You can always ask an expert in the Excel Tech Community or get support in the Answers community.

Learn how to use nested functions in a formula

IF function

AND function

OR function

NOT function

Overview of formulas in Excel

How to avoid broken formulas

Detect errors in formulas

Keyboard shortcuts in Excel

Logical functions (reference)

Excel functions (alphabetical)

Excel functions (by category)

The “greater than or equal to” is a comparison or logical operator that helps compare two data cells of the same data type. It is denoted by the symbol “>=” and returns the following values:

  • “True,” if the first value is either greater than or equal to the second value
  • “False,” if the first value is smaller than the second value

Generally, the “greater than or equal to” operator is used for date and time values and numbers. It can also be used for textual data.

For example, if cell C1 contains “rose” and cell D1 contains “lotus,” the formula “=C1>=D1” returns “true.” This is because the first letter “r” is greater than the letter “l.” The values “a” and “z” are considered the lowest and the highest text values respectively.

Table of contents
  • The “Greater Than or Equal To” (>=) in Excel
    • Logical and Arithmetic Operators
    • How to Use “Greater Than” (>) and “Greater Than or Equal to” (>=)?
      • Example #1–“Greater Than” and “Greater Than or Equal to”
      • Example #2–“Greater Than or Equal to” With the IF Function
      • Example #3–“Greater Than or Equal to” With the COUNTIF Function
      • Example #4–“Greater Than or Equal to” With the SUMIF Function
    • Frequently Asked Questions
    • Recommended Articles

Logical and Arithmetic Operators

The “equal to” (=) symbol, used in mathematical operations, helps find whether two values are equal or not. Likewise, every logical operatorLogical operators in excel are also known as the comparison operators and they are used to compare two or more values, the return output given by these operators are either true or false, we get true value when the conditions match the criteria and false as a result when the conditions do not match the criteria.read more serves a particular purpose. Since logical operators return only the Boolean values “true” or “false,” they are also called Boolean operators.

The logical operators help draw relevant conclusions which are used in the decision-making process.

 The arithmetic operators like “plus” (+), “minus” (-), “asterisk” (*), “forward slash” (/), “percent” (%), and “caret” (^) symbols are used in formulas. These operators are used in calculations to generate numeric output.

The “asterisk,” “forward slash,” and “caret” are used for multiplication, division, and exponentiation respectively.

How to Use “Greater Than” (>) and “Greater Than or Equal to” (>=)?

Let us consider a few examples to understand the usage of the given comparison operators in Excel.

You can download this Greater Than or Equal to Excel Template here – Greater Than or Equal to Excel Template

Example #1–“Greater Than” and “Greater Than or Equal to”

The following list shows five numerical values from cell A2 to A6. We want to test whether each number is greater than 50 or not.

Example 1

The steps to test the greater number are listed as follows:

  1. Type the “equal to” (=) sign in cell B2.

    Greater than & equal to Example 1-1

  2. Select the cell A2 that is to be tested.

    Greater than & equal to Example 1-2

  3. Since we want to test whether the value in cell A2 is greater than 50 or not, type the comparison operator (>) followed by the number 50.

    Greater than & equal to Example 1-3

  4. Press the “Enter” key to obtain the result. Copy and paste or drag the formula to the remaining cells. The cells in yellow contain a number greater than 50. Hence, the result is “true”.

    The value of cell A4 (50) is not greater than the number 50. Hence, the result in cell B4 is “false”.

    Greater than & equal to Example 1-4

    To include 50 in the test, we need to change the comparison operator to “greater than or equal to” (>=).

    The “greater than or equal to” operator returns the value “true” in cell B4. This implies that the value of cell A4 is either greater than or equal to 50.

    Greater than & equal to Example 1-5

Example #2–“Greater Than or Equal to” With the IF Function

Let us use the comparison operator “greater than or equal to” with the IF conditionIF function in Excel evaluates whether a given condition is met and returns a value depending on whether the result is “true” or “false”. It is a conditional function of Excel, which returns the result based on the fulfillment or non-fulfillment of the given criteria.
read more
.

The following table shows the total sales (in dollars) of various months. The monthly incentives are calculated by comparing the sales against the benchmark of $6500. The possibilities are stated as follows:

  • If the total sales>$6500, incentives are calculated at 10%.
  • If the total sales<$6500, incentives are 0.

Equal to with If Step 1

Step 1: Open the IF function. The IF function helps evaluate a criterion and returns “true” or “false” depending on whether the condition is met or not.

Equal to with If Step 2

Step 2: Apply the logical testA logical test in Excel results in an analytical output, either true or false. The equals to operator, “=,” is the most commonly used logical test.read more, B2>6500.

Equal to with If Step 3

Step 3: The condition is that if the logical test is “true,” we calculate the incentives as B2*10%. So, we type this criterion.

Equal to with If Step 4

Step 4: If the logical test is “false,” the incentives are 0. So, we type zero at the end of the formula.

In cell C2, the formula returns the output 0. This implies that the value in cell B2 is less than $6500.

Equal to with If Step 5

Step 5: Drag the formula to the remaining cells, as shown in the following image.

Since the values in the cells B5, B11, B12, and B13 are greater than $6500, we get the respective incentive amounts in column C.

Equal to with If Step 6

Example #3–“Greater Than or Equal to” With the COUNTIF Function

Let us use the comparison operator “greater than or equal to” with the COUNTIFThe COUNTIF function in Excel counts the number of cells within a range based on pre-defined criteria. It is used to count cells that include dates, numbers, or text. For example, COUNTIF(A1:A10,”Trump”) will count the number of cells within the range A1:A10 that contain the text “Trump”
read more
function.

The following table shows the date and amount of the invoices sent to the buyer. We want to count the number of invoices that are sent on or after 14th March 2019.

Equal to with COUNTIF Step 1

Step 1: Open the COUNTIF function. The COUNTIF function helps count the cells within a particular range based on a criterion.

Equal to with COUNTIF Step 2

Step 2: Select the date column (column A) as the range (A2:A13).

Equal to with COUNTIF Step 3

Step 3: Since the criterion is on or after 14th March 2019, it can be represented as “>=14-03-2019.” Type the symbol “>=” in double quotation marks.

Note: The comparison operators in the “criteria” argument must be placed within double quotation marks.

Equal to with COUNTIF Step 4

Step 4: Type the ampersand sign (&). We supply the date with the DATE functionThe date function in excel is a date and time function representing the number provided as arguments in a date and time code. The result displayed is in date format, but the arguments are supplied as integers.read more. This is because we are not using the cell referencesCell reference in excel is referring the other cells to a cell to use its values or properties. For instance, if we have data in cell A2 and want to use that in cell A1, use =A2 in cell A1, and this will copy the A2 value in A1.read more of date values.

Equal to with COUNTIF Step 5

Step 5: Close the brackets of the formula and press the “Enter” key.

The output is 7, implying that a total of seven invoices are generated on or after 14th March 2019.

Equal to with COUNTIF Step 6

Example #4–“Greater Than or Equal to” With the SUMIF Function

Let us use the comparison operator “greater than or equal to” with the SUMIFThe SUMIF Excel function calculates the sum of a range of cells based on given criteria. The criteria can include dates, numbers, and text. For example, the formula “=SUMIF(B1:B5, “<=12”)” adds the values in the cell range B1:B5, which are less than or equal to 12.
read more
function.

The following table shows the monthly sales of an organization. The sales figures are reported in thousand dollars. We want to find whether the total sales are greater than or equal to $20,000.

Equal to with SUMIF Step 1

Step 1: Open the SUMIF function. The SUMIF function sums the cells based on a specified criterion.

Equal to with SUMIF Step 2

Step 2: Select the sales column (column B) as the “range” ($B$2:$B$13). This helps sum the monthly sales values.

SUMIF Step 3

Step 3: Type the “criteria” as “>=”&20. Place the comparison operator within the double quotation marks.

SUMIF Step 4

Step 4: Select the “sum_range” same as the “range” argument, i.e., $B$2:$B$13.

The output is $132,000. Hence the total sales are greater than $20,000.

SUMIF Step 5

Frequently Asked Questions

Define the “greater than or equal to” operator in Excel.

The “greater than or equal to” (>=) is one of the six comparison or logical operators of Excel. It returns “true” if the first number is greater than or equal to the second number; otherwise returns “false”.

The remaining comparison operators are “equal to” (=), “not equal to” (<>), “greater than” (>), “less than” (<), and “less than or equal to” (<=). All the comparison operators help compare two data cells. They can be used with numbers, text, and date and time values.

For example, the formula “=C2>=SUM(F2:H11)” returns “true” if the value in cell C2 is greater than or equal to the sum of values in the range F2:H11. If the converse is correct, it returns “false”.

When should the “greater than or equal to” operator be used in Excel?

The given comparison operator should be used in the following situations:

• To find which of the two quantities is greater or smaller
• To find whether one quantity is equal to the other
• To evaluate two quantities with respect to a given criteria
• To compare two separate quantities with a third quantity

Note: Two quantities can be compared only if both are of the same data type.

How is the “greater than or equal to” symbol written in Excel?

The “greater than or equal to” symbol (>=) is written in Excel by typing the “greater than” (>) sign followed by the “equal to” (=) operator.

The operator “>=” is placed between two numbers or cell references to be compared. For example, type the formula as “=A1>=A2” in Excel.

The symbol “>=” is placed within double quotation marks when entered in the “criteria” argument of SUMIF and COUNTIF functions. For example, type the formula as “=SUMIF(B2:B11,”>=100″)” in Excel.

Note: The two formulas of Excel (in the preceding examples) should be entered excluding spaces and without the beginning and ending quotation marks.

Recommended Articles

This has been a guide to “greater than or equal to” in Excel. Here we discuss how to use “greater than” and “greater than or equal to” (>=) with IF, SUMIF, and COUNTIF formulas along with examples and downloadable Excel templates. You may also look at these useful functions in Excel –

  • “Not Equal” in VBA
  • Excel Formula for COUNTIF
  • Not Equal to in Excel
  • List of Excel Functions

In Excel, <> means not equal to. The <> operator in Excel checks if two values are not equal to each other.

Contents

  • 1 Does not equal in Excel if statement?
  • 2 Is there an if not function in Excel?
  • 3 How do you use not equal in an if statement?
  • 4 Why does Excel say cell values are not equal when they are?
  • 5 What does not function mean?
  • 6 What is not greater than Excel?
  • 7 How do I write not greater than in Excel?
  • 8 What is the meaning of &&?
  • 9 How do I use an IF function in Excel?
  • 10 What is the symbol for does not equal?
  • 11 How do I remove spaces from excel?
  • 12 How do I compare two text cells in excel?
  • 13 How do I find the difference between two text cells in excel?
  • 14 What are examples of non functions?
  • 15 What makes a function not a function?
  • 16 How do you use less than equal to in Excel?
  • 17 How do you count less than in Excel?
  • 18 How do you find less than greater than in Excel?
  • 19 How do you write less than equal to?
  • 20 How do you write less than or equal to?

Does not equal in Excel if statement?

Excel’s “does not equal” operator is simple: a pair of brackets pointing away from each other, like so: “<>“. Whenever Excel sees this symbol in your formulas, it will assess whether the two statements on opposite sides of these brackets are equal to one another.

Is there an if not function in Excel?

The NOT function is an Excel Logical function. The function helps check if one value is not equal to another. If we give TRUE, it will return FALSE and when given FALSE, it will return TRUE.

How do you use not equal in an if statement?

Note however, that an equal comparison is done with two equal signs, not one. Also, “less than or equal to” is written as it’s pronounced: <= and not =<; ditto for “greater than or equal to,” which cannot be written =>. Not-equal is written !=
How to Construct a Basic IF Statement in C.

Operator Meaning Example
!= Not equal to odd != 2

Why does Excel say cell values are not equal when they are?

Spaces Before or After Your Values
These ‘ghost’ characters take form as spaces and if they occur in the beginning or end of text, we cannot see any visual evidence of their existence! In the example below, Cell C2 is testing to see if A2 = B2. This text is giving us a FALSE which means they do not equal each other.

What does not function mean?

The NOT function reverses the value of its argument. One common use for the NOT function is to expand the usefulness of other functions that perform logical tests.Logical Required. A value or expression that can be evaluated to TRUE or FALSE.

What is not greater than Excel?

The formula returns TRUE if a value in cell A1 is greater than a value in cell B1; otherwise it returns FALSE.
Using “Not equal to” logical operator in Excel.

Not equal to operator NOT function Description
=A1<>TRUE =NOT(A1=TRUE) Returns TRUE if cell A1 contains any value other than TRUE, FALSE otherwise.

How do I write not greater than in Excel?

Define the “greater than or equal to” operator in Excel.
The remaining comparison operators are “equal to” (=), “not equal to” (<>), “greater than” (>), “less than” (<), and “less than or equal to” (<=). All the comparison operators help compare two data cells.

What is the meaning of &&?

The && (logical AND) operator indicates whether both operands are true. If both operands have nonzero values, the result has the value 1 . Otherwise, the result has the value 0 .

How do I use an IF function in Excel?

When you combine each one of them with an IF statement, they read like this:

  1. AND – =IF(AND(Something is True, Something else is True), Value if True, Value if False)
  2. OR – =IF(OR(Something is True, Something else is True), Value if True, Value if False)
  3. NOT – =IF(NOT(Something is True), Value if True, Value if False)

What is the symbol for does not equal?


Not equal. The symbol used to denote inequation (when items are not equal) is a slashed equal sign ≠ (U+2260).

How do I remove spaces from excel?

Remove all spaces between numbers

  1. Press Ctrl + Space to select all cells in a column.
  2. Press Ctrl + H to open the “Find & Replace” dialog box.
  3. Press Space bar in the Find What field and make sure the “Replace with” field is empty.
  4. Click on the “Replace all” button, and then press Ok. Voila! All spaces are removed.

How do I compare two text cells in excel?

Compare Text

  1. Use the EXACT function (case-sensitive).
  2. Use the formula =A1=B1 (case-insensitive).
  3. Add the IF function to replace TRUE and FALSE with a word or message.
  4. Do you want to compare two or more columns by highlighting the differences in each row?

How do I find the difference between two text cells in excel?

Compare two strings with formula
Select a blank cell C2, enter formula =EXACT(A2, B2) into the Formula Bar, and then press the Enter key. See screenshot: Note: In the formula, A2 and B2 are the cells containing the comparing strings.

What are examples of non functions?

Horizontal lines are functions that have a range that is a single value. Vertical lines are not functions. The equations y=±√x and x2+y2=9 are examples of non-functions because there is at least one x-value with two or more y-values.

What makes a function not a function?

If we can draw any vertical line that intersects a graph more than once, then the graph does not define a function because that x value has more than one output. A function has only one output value for each input value.

How do you use less than equal to in Excel?

‘Less Than or Equal to’ operator (<=) is one of the six logical operators (also known as the comparison operators) used in Microsoft Excel to compare values. The “<=” operator checks if the first value is less than or equal to the second value and returns ‘TRUE’ if the answer is yes or else ‘FALSE’.

How do you count less than in Excel?

In this article, we will focus on the Excel COUNTIF function that is purposed for counting cells with the condition you specify.
COUNTIF greater than, less than or equal to.

Criteria Formula Example Description
Count if less than or equal to =COUNTIF(C2:C8,”<=5″) Count cells where value is less than or equal to 5.

How do you find less than greater than in Excel?

The greater than (>) and less than (<) operators
The greater than operator returns TRUE if the first value compared is larger than the second. The less than operator returns TRUE if the first value is smaller than the second. Both operators will return FALSE if the values are equal.

How do you write less than equal to?

The less than symbol is <. Two other comparison symbols are ≥ (greater than or equal to) and ≤ (less than or equal to).

How do you write less than or equal to?

About This Article

  1. Press and hold the Alt key and type 243 on your keypad.
  2. Release the Alt key.

Equal to | Greater than | Less than | Greater than or equal to | Less than or equal to | Not equal to

Use comparison operators in Excel to check if two values are equal to each other, if one value is greater than another value, if one value is less than another value, etc.

Equal to

The equal to operator (=) returns TRUE if two values are equal to each other.

1. For example, take a look at the formula in cell C1 below.

Equal To Operator in Excel

Explanation: the formula returns TRUE because the value in cell A1 is equal to the value in cell B1. Always start a formula with an equal sign (=).

2. The IF function below uses the equal to operator.

If Function

Explanation: if the two values (numbers or text strings) are equal to each other, the IF function returns Yes, else it returns No.

Greater than

The greater than operator (>) returns TRUE if the first value is greater than the second value.

1. For example, take a look at the formula in cell C1 below.

Greater Than Operator

Explanation: the formula returns TRUE because the value in cell A1 is greater than the value in cell B1.

2. The OR function below uses the greater than operator.

Or Function

Explanation: this OR function returns TRUE if at least one value is greater than 50, else it returns FALSE.

Less than

The less than operator (<) returns TRUE if the first value is less than the second value.

1. For example, take a look at the formula in cell C1 below.

Less Than Operator

Explanation: the formula returns TRUE because the value in cell A1 is less than the value in cell B1.

2. The AND function below uses the less than operator.

And Function

Explanation: this AND function returns TRUE if both values are less than 80, else it returns FALSE.

Greater than or equal to

The greater than or equal to operator (>=) returns TRUE if the first value is greater than or equal to the second value.

1. For example, take a look at the formula in cell C1 below.

Greater Than or Equal To Operator

Explanation: the formula returns TRUE because the value in cell A1 is greater than or equal to the value in cell B1.

2. The COUNTIF function below uses the greater than or equal to operator.

Countif Function

Explanation: this COUNTIF function counts the number of cells that are greater than or equal to 10.

Less than or equal to

The less than or equal to operator (<=) returns TRUE if the first value is less than or equal to the second value.

1. For example, take a look at the formula in cell C1 below.

Less Than or Equal To Operator

Explanation: the formula returns TRUE because the value in cell A1 is less than or equal to the value in cell B1.

2. The SUMIF function below uses the less than or equal to operator.

Sumif Function

Explanation: this SUMIF function sums values in the range A1:A5 that are less than or equal to 10.

Not Equal to

The not equal to operator (<>) returns TRUE if two values are not equal to each other.

1. For example, take a look at the formula in cell C1 below.

Not Equal To Operator

Explanation: the formula returns TRUE because the value in cell A1 is not equal to the value in cell B1.

2. The IF function below uses the not equal to operator.

If Formula

Explanation: if the two values (numbers or text strings) are not equal to each other, the IF function returns No, else it returns Yes.

Skip to content

Logical Operators in Excel: Less Than, Greater Than (+More!)

Logical Operators in Excel: Less Than, Greater Than (+More!)

We all have read about logical operators in high school – even if we didn’t like them then.

Similar to those, Excel provides comparison operators that return the result in TRUE or FALSE.

These operators are like “less than or equal to” and “greater than or equal to” which are very helpful in quick data analysis.

In this guide, we will discuss all the aspects of logical operators and see how to use them. So stay tuned! 🤗

Also, if you want to practice along the guide, you can get our free sample workbook here.

What are logical operators in Excel?

Logical operators are also known as comparison operators because their primary purpose is to compare two values.

These operators always only consider the value. And that’s regardless of how it is derived – even if it’s from a formula.

Also, a logical operator never returns numerical values in the result, only TRUE and FALSE. The value of TRUE and FALSE is 1 and 0, respectively – which are binary digits.

The comparison operators can also handle any Boolean expression. Hence, they are called Boolean operators.

In Excel, there are six Boolean operators you can use. These are:

  • Less than
  • Less than or equal to
  • Greater than
  • Greater than or equal to
  • Equal to
  • Not Equal to

Let’s study all these operators in depth below 🚀

Less than in Excel

As evident from the name, the ‘Less than’ operator checks if the first value is less than the second value or not. If it is, it returns TRUE; otherwise, it returns FALSE, and it is denoted by <.

Let’s understand its concept using an example.

We have the following data set.

Sample data for following formula.

We want to check if cell A2 is less than cell B2. For that:

  1. Select cell C2.
  2. Type in the formula

=A2<B2

Entering Excel formula for Less than arithmetic operators.
  1. Press Enter.

Excel shows the result as follows:

Result of the logical test.

To do the same for all other entries, simply double-click the Fill Handle as:

Fill Handle fills all the values.

Pro Tip!

Excel can also compare text values, but by their alphabetical order. It compares the first letters of both values. And determines which of the two falls lower in the order.

However, if both the first values are the same, the operator moves on to the second one, and so forth 😀

Less than or equal to in Excel

The ‘Less than or equal to’ operator is the same as the ‘Less than’ operator. The only difference is that it returns TRUE if the first value is smaller or equal to the second value. It is represented by <=

Let’s see it working through a quick example.

We have identical values in the first two cells below.

Sample data for less than and equal to.

If we apply the formula:

=A2<=B2

Excel would return the result TRUE.

`Result for less than or equal to

Similarly, if we reduce the value of cell A2, it would still show TRUE as:

Result with different value.

That’s because the condition is to return TRUE if the first value is less than or equal to the second value. Since the value, in this case, is lesser, Excel returns TRUE. Otherwise, it would return FALSE.

Less than or equal to’ example with the IF function

You can also combine logical operators with Excel functions.

Let’s see an example using the IF function with the ‘Less than or equal to’ operator below.

Suppose, we have the following data set.

Sample data for the If function

We want to check if the first value in A2 is less than or equal to the value in cell B2 or not. If it is, the IF function will return ‘Right,’ and if it is not, it will return ‘Wrong.’

So, for this, we will enter the formula:

=IF (A1<=B1, “Right,” “Wrong”)

Formula for the IF function
Result of If function with less than or equal to operator

The IF function returns “Right” because the values in cells A2 and B2 are equal.

Double Click the Fill Handle to copy the formula to the remaining entries.

Fill Handle copies the result to remaining rows.

Excel returns “Right” for all the values that fulfill the condition, i.e., are less than or equal to the second value. And for the ones that don’t fulfill the condition, Excel returns “Wrong.”

Greater than in Excel

The ‘Greater than’ logical operator checks if the first value is greater than the second. It’s the opposite of the ‘Less than’ operator and is denoted by >.

Let’s see it using an example 👀

We have the following data.

Sample data for Greater than in Excel.

We want to check if the value in cell A2 is greater than the value in cell B2. For that:

  1. Select C2.
  2. Enter the formula

=A2>B2

Formula for Greater than or equal sign
  1. Hit Enter.
Result for greater than comparison operator

The result TRUE shows that cell A2 is greater than cell B2.

Drag down the Fill Handle to copy the formula.

Fill Handle fills all the values.

Pro Tip!

For text values, the ‘Greater than’ operator begins the count from the bottom of the English alphabet – Z.

‘Greater than’ example with the SUMIF Function

Let’s see how to use the ‘Greater than’ operator with the SUMIF function below.

We have the following sample data.

Sample data for the SUMIF function

To use the SUMIF function, we will apply the formula:

=SUMIF(A2:A7, “>”&B2, B2:B7)

SUMIF formula

Note that we have used the “&” ampersand after the logical operator. This is because our target value was in another cell, so we used the cell reference and joined it with the condition.

Comment

Make sure to enclose the logical operators in double quotation marks as we did above. Otherwise, they are considered to be text strings.

Kasper Langmann, Microsoft Office Specialist

Press Enter and Excel returns the result:

Result of the SUMIF function with Greater than operator

And tada! It’s done. That’s how easy it is to use the SUMIF function with the ‘Greater than’ operator 😉

Greater than or equal to in Excel

As the name suggests, the ‘Greater than or equal’ sign tells if a value is greater than or equal to its counterpart. If it is, the operator returns TRUE otherwise, it returns FALSE. The ‘Greater than or equal’ operator is denoted by ≥.

Let’s see how it works through an example below.

We have the following example data.

If we apply the ‘Greater than or equal to’ operator on cells A2 and B2 as:

=A2>=B2

Greater than operator formula

Excel returns TRUE as both the values are equal to each other.

Result of the greater than or equal to operator

Similarly, if we increase the value of cell A2 by 1, the result will remain the same.

Greater value returns TRUE.

That’s because the condition given is to check if the value in the first cell is greater than the value in the second cell or equal to it.

Not equal to in Excel

The ‘Not equal to’ operator is self-explanatory!

But the symbol is not🤔

It is denoted <>, and it returns FALSE if two values are equal to each other; otherwise, it returns TRUE. It is the opposite of the ‘Equal to’ operator.

Let’s see it in action through an example.

This is our sample data.

Sample data for not equal operator

We will apply the ‘Not equal to’ operator to cells A2 and B2 as:

=A2<>B2

Formula for Not equal to

Excel returns FALSE as a result:

Result of Not equal to

Here Excel returned FALSE because both the cell values were the same. And the ‘Not equal to’ operator returns FALSE for identical values.

To copy the same formula down the rows, double-click the Fill Handle.

Fill handles copies the values.

Excel copied the formula to the remaining rows 😊

That’s it – Now what?

And tada! You now know everything about Excel logical operators 🥳

We learned so much about them in this article. We saw how the ‘Less than’ and ‘Greater than’ operators work. We also learned how to use them with text values and interpret the answer.

All this knowledge takes us one step closer to Excel mastery. But it doesn’t end here. This giant spreadsheet has tons of other things to offer.

If you want to polish your Excel skills, we recommend you master the VLOOKUP, IF, and SUMIF functions.

You learn those in my 30-minute free course delivered straight to your inbox. So enroll now and learn these fantastic functions!

Other resources

Boolean operators are very useful when you need quick results for extensive data. And even more useful when combined with Excel functions like COUNTIF function and SUMIF function, etc.

If you enjoyed reading this article, we bet you’d want to learn more. Some related topics include the IF, TRUE & FALSE, and Excel Logical Functions.

Frequently asked questions

It’s simple. You can use the ‘Less than or equal to’ operator in formulas like =A3<= SUM(C2:C6). Excel will return the result TRUE if the value in A3 is less than or equal to the result of SUM; otherwise FALSE.

Yes, you can. The >= operator symbolizes the ‘Greater than or equal’ condition. It returns TRUE if a certain value is greater than or equal to its counterpart and vice versa.

Excel lets you use logical operators with multiple Excel functions. The IF function is most common for combining with comparison operators. An example could be =IF (A1>=B1, “Pass,” “Fail”). This tells the function to return Pass if the condition is TRUE; otherwise, Fail.

Kasper Langmann2023-01-04T18:52:07+00:00

Page load link

Like this post? Please share to your friends:
  • Is not error миф excel
  • Is not a swear word
  • Is northeast one word
  • Is non stop one word
  • Is noisily a word