AND Function In Google Sheets

What Is AND Function In Google Sheets?

The AND function in Google Sheets is a logical function that returns TRUE or FLASE values based on two or more conditions. It returns TRUE if all the logical values or conditions are true.

Since the Google Sheets AND function returns logical values, we can combine it with other functions such as, IF(), OR(), etc. with single or multiple conditions. For example, the below table shows the performance of employees with their achieved targets.

AND Google Sheets function Definition 1

Select the cell C2, enter the formula =AND(B2>=50), press the β€œEnter” key and once we get the result, drag the formula from cell C2 to C6 using the fill handle.

AND Google Sheets function Definition 1-1
Key Takeaways
  • The AND function in Google Sheets checks two or more conditions and returns TRUE if all the conditions are TRUE, else it returns FALSE.
  • The formula has one mandatory argument that refers to the first logical value to be tested and other optional arguments that denote the second or the corresponding logical values and so on.
  • The function reads operators such as equal to, not equal to, greater than, less than, greater than or equal to, lesser than or equal to, etc.
  • The function ignores blank values and returns #VALUE! error if the arguments have empty cells.

AND( ) Google Sheets Formula

The syntax of the AND Google Sheets Formula is:

AND( ) Google Sheets Formula

The arguments of the AND Google Sheets Formula are:

  • logical_expression1: It is a mandatory argument and refers to the first logical value to be tested.
  • [logical_expression2, logical_expression3, and …]: It is an optional argument that denotes the second or the corresponding logical value.

Operators Used In The AND Function

The AND in Google Sheets involves some operators to perform certain tasks. The names and symbols of the operators are shown in the table below:

OperatorsNames
=Equal to
<> Not Equal to
Greater than
Less than
>=Greater than or equal to
<=Lesser than or equal to

How To Use AND In Google Sheets?

We can use the AND In Google Sheets in 2 ways, namely,

  1. Access from the Google Sheets ribbon.
  2. Enter in the worksheet manually.

Method #1 – Access From the Google Sheets Ribbon 👒

Choose an empty cell for the output Γ  select the β€œInsert” tab Γ  click the β€œFunction” option right arrow Γ  click the β€œLogical” option right arrow Γ  select the β€œAND” function, as shown below.

How To Use AND In Google Sheets 1

The β€œAND” formulaappears, as shown below. Enter the argument as the cell reference.

AND( ) Google Sheets Formula

Method #2 – Enter in the Worksheet Manually 👒

  1. Select an empty cell for the output.
  2. Type =AND( in the cell. [Alternatively, type =A or =AND and double-click the AND function from the Google Sheets suggestions.]
  3. Enter the arguments as cell values or cell references and close the brackets.
  4. Press Enter to view the outcome.

Examples

Let us understand how the AND function in Google Sheets works with some examples.

Example #1 – Test Multiple Conditions Using AND Function

Consider the below table listing the students’ scores in columns, A and B, respectively. We will test multiple conditions such as, whether the students have scored greater than or equal to 60 or not, also if the score is less than 80.

AND function in Google Sheets Example 1

The steps to obtain the results for multiple conditions using the AND function are as follows:

Step 1: Select cell C2 and enter the formula =AND(B2>=60

AND function in Google Sheets Example 1-1

Step 2: Let us enter the second condition, whether the entered values are less than 80. Therefore, type B2<80 next to the first argument, as shown below. The formula now is =AND(B2>=60,B2<80

AND function in Google Sheets Example 1-2

Step 3: Close the brackets and press Enter key. The AND function has returned the value as TRUE in cell C2.

AND function in Google Sheets Example 1-3

Step 4: Drag the formula from cell C2 to C6 using the fill handle.

AND function in Google Sheets Example 1-4

The AND function has found that cells B2, B3 and B5 satisfy both the conditions.

Example #2 – AND + OR Function 👒

The below table shows the number of available bedsheets (double and single) in the store. We will check for multiple conditions using the OR and the AND function in Google Sheets.

In the table,

  • Column A shows the total number of bedsheets.
  • Column B displays the available double bedsheets.
  • Column C displays the available single bedsheets.
  • The results obtained should be displayed in column D.
AND function in Google Sheets Example 2

The steps to obtain results using OR and AND in Google Sheets are as follows:

Step 1: Select cell D2 and enter the formula =AND(A2>=50,

AND function in Google Sheets Example 2-1

Step 2: We will also check whether the entered value in column B is greater than or equal to β€˜20’ and the value in column C is greater than or equal to β€˜15’ using OR function.

So, type OR(B2>=20),OR(C2>=15) in the formula and close the AND function with the bracket.

The complete formula is =AND(A2>=50,OR(B2>=20),OR(C2>=15)).

If both the conditions are true, OR with AND function returns TRUE; if the data does not satisfy the conditions, it returns FALSE.

AND function in Google Sheets Example 2-2

Step 3: Press Enter key. The OR with AND function has returned the value as FALSE in cell D2, as shown below.

AND function in Google Sheets Example 2-3

Step 4: Drag the formula from cell D2 to D6 using the fill handle. The OR with AND functions has returned the availability status using the conditions, >=20 and >=15, to get the output shown below.

AND function in Google Sheets Example 2-4

Example #3 – AND + IF Function 👒

The following table lists fruits along with the stock and demand details. We need to find the fruits with and without sales using IF and the AND function in Google Sheets.

In the table,

  • Column A displays the fruits.
  • Column B shows the stock.
  • Column C indicates the demand for the fruits.
  • The results obtained should be displayed in column D.
AND function in Google Sheets Example 3

The steps to obtain results using the IF and the AND function in Google Sheets are as follows:

Step 1: Select cell D2 and enter the formula =IF(AND

AND function in Google Sheets Example 3-1

Step 2: We should select the cell with the first value (first argument), i.e., cell B2.

AND function in Google Sheets Example 3-2

Step 3: Let us check whether the entered values are greater than or equal to 30 (>=30).

So, type >=30 next to the first argument.

AND function in Google Sheets Example 3-3

Step 4: We need to select the corresponding second value (second argument), i.e., cell C2. We will also check whether the data is high in demand or not. High demand indicates that the fruit can be sold easily. So, type = β€œHigh” in the formula and close the AND function with the bracket.

AND function in Google Sheets Example 3-4

The IF function returns the value with TRUE or FALSE conditions. So, in this example, if both the conditions are TRUE, then the function returns β€œSale” and returns the output as β€œNo Sale” when the conditions are FALSE.

The complete formula is =IF(AND(B2>=30,C2=β€œHigh”),β€œSale”,β€œNo Sale”)

AND function in Google Sheets Example 3-5

Step 5: Close the brackets and press Enter key to get the output, as Sale, as shown below.

AND function in Google Sheets Example 3-6

Step 6: Drag the formula from cell D2 to D6 using the fill handle.

AND function in Google Sheets Example 3-7

The AND with IF Google Sheets functions have found that bananas have a high demand value and satisfies the condition, >=30. Also, the TRUE or FALSE conditions are indicated using β€˜Sale’ and β€˜No Sale’ conditions.

Example #4 – Find Output Using Operators 👒

The below table shows two values, V1 and V2, in columns A and B. We will use the Google Sheets AND function to find the output using operators.

AND function in Google Sheets Example 4

The procedure to find results using the operators are as follows:

Select cell C2 and enter the formula =AND(A2=B2), as shown below.

AND function in Google Sheets Example 4-1

Press β€œEnter” to get the output shown below.

AND function in Google Sheets Example 4-2

Important Things To Note

  • The #VALUE! error occurs when an argument is blank or if no logical value is found.
  • The AND function tests the conditions and returns TRUE or FALSE values.

Frequently Asked Questions

1) When to use the AND function in Google Sheets?

The AND function in Google Sheets is used when we have two or more conditions to test and wants the output value as TRUE or FALSE.
1. The function is used when several conditions need to be tested simultaneously.
2. It is used with the IF function when more than one condition must be tested.
3. The function is used with the OR function to compare two or more values.

2) What is an alternate way to insert the AND Google Sheets function?

We often forget in which category a function falls, here, the β€œAND” function. Then, we can insert the function as follows:

Choose an empty cell 👒 select the β€œInsert” tab 👒 click the β€œFunction” option right arrow 👒 click the β€œAll” option right arrow 👒 select the β€œAND” function, as shown below.
AND Google Sheets function FAQ 1
However, as always, entering the function manually is the best way to avoid confusion.

3) Where else can we find the AND function in Google Sheets?

Alternatively, we can find the Functions icon to insert the AND function by following the path shown below.
β€’ Choose an empty cell 👒 click the β€œMore” option represented by the three vertical dots at the end of the toolbar, as shown below.
AND Google Sheets function FAQ 1-1
β€’ A list of icons appears when we click the β€œMore” option. Here, click the β€œFunctions” icon, as shown below.
AND Google Sheets function FAQ 1-2
β€’ Here, click the β€œFunctions” option 👒 click the β€œAll” option right arrow 👒 select the β€œAND” function, as shown below.
AND Google Sheets function FAQ 1-3

Download Template

This article must help understand AND function in Google Sheets with its formulas and examples. You can download the template here to use it instantly.

Guide to AND Function In Google Sheets. We learn about the AND function, its formula and the operators used with examples & working template. You can learn more from the following articles. –

Spell Check In Google Sheets

MEDIAN Google Sheets Function

DATEVALUE In Google Sheets

Reader Interactions

Leave a Reply

Your email address will not be published. Required fields are marked *