How to Compare Three Columns in Google Sheets


You can use the following basic formula to compare three columns in Google Sheets:

=IF(AND(B2=C2,C2=D2),"Equal","Not Equal")

This particular formula compares the values in cells B2, C2, and D2.

If all of the values are equal, the formula returns Equal. Otherwise, it returns Not Equal.

The following example shows how to use this formula in practice.

Example: Compare Three Columns in Google Sheets

Suppose we have the following dataset that shows the highest scorer on various basketball teams during three different games:

We can type the following formula into cell E2 to test if the three values in the first row are all equal:

=IF(AND(B2=C2,C2=D2),"Equal","Not Equal")

We can then drag this formula in cell E2 down to the remaining cells in column E to test for matches in each row:

Notice that the formula only returns Equal for the rows where the cell values are equal across each of the three columns.

For example:

  • The first row displays Equal since each value in columns B through D is equal to Doug.
  • The second row displays Equal since each value in columns B through D is equal to Mike.
  • The third row displays Not Equal since the values in columns B through D are not all equal.

And so on.

Additional Resources

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

How to Compare Dates in Google Sheets
How to Compare Two Columns in Google Sheets

Leave a Reply

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