Can you use TRUE or FALSE in a VLOOKUP when working with Google Sheets?

The VLOOKUP function in Google Sheets is a useful tool for finding and retrieving data from a specific column in a spreadsheet. It allows users to search for a specific value and return a corresponding value from a different column. When utilizing the VLOOKUP function, it is important to note that it only works with numerical or text data. Therefore, the use of TRUE or FALSE values is not possible as they are logical values and cannot be searched for in a column. Instead, users should input the desired text or numerical value to search for. This will ensure accurate results when using the VLOOKUP function in Google Sheets.

Google Sheets: Use TRUE or FALSE in VLOOKUP


You can use the VLOOKUP function in Google Sheets to look up some value in a range and return a corresponding value.

This function uses the following syntax:

VLOOKUP(search_key, range, index, [is_sorted])

where:

  • search_key: The value you want to look up
  • range: The range of cells to search for the lookup value
  • index: The column number that contains the return value
  • is_sorted: TRUE = approximate match, FALSE = exact match

Notice that the last argument allows you to specify TRUE to look for an approximate match of the value you want to look up or FALSE for an exact match.

The default value is TRUE, but in most cases you will use FALSE because you want to find an exact match of the value you’re looking for.

When using TRUE, the VLOOKUP function will often return unexpected and inaccurate results.

The following examples show the difference between using TRUE and FALSE in the VLOOKUP function with the following dataset in Google Sheets:

Example 1: Using VLOOKUP with TRUE

Suppose we use the following formula with VLOOKUP to look up the team names in column D and return the corresponding value from the points column:

=VLOOKUP(D2, $A$2:$B$10, 2, TRUE)

The following screenshot shows how to use this formula in practice:

Google Sheets VLOOKUP with TRUE

Since we specified TRUE for the last argument in VLOOKUP, we looked for “approximate” matches for the team names.

Notice that none of the points values returned in column E match the team names from column D.

Example 2: Using VLOOKUP with FALSE

Suppose we use the following formula with VLOOKUP to look up the team names in column D and return the corresponding value from the points column:

=VLOOKUP(D2, $A$2:$B$10, 2, FALSE) 

The following screenshot shows how to use this formula in practice:

Google Sheets VLOOKUP with FALSE

Since we specified FALSE for the last argument in VLOOKUP, we looked for exact matches for the team names.

Notice that each of the points values returned in column E match the team names from column D.

By using FALSE, we were able to accurately find the team names in the original dataset and return their corresponding points value.

Note: You can find the complete documentation for the Google Sheets VLOOKUP function .

Additional Resources

The following tutorials explain how to perform other common operations in Google Sheets:

x