Comparing Two Columns of Data

  • Thread starter Thread starter par1211
  • Start date Start date
P

par1211

Is there a way to compare the data in two separate columns? For instance,
if I have two columns of what is supposed to be identical data, is there a
way to compare them to make sure that they are identical? The data is text,
if that make a difference and it is coming from two different sources. I
would need to investigate which entry would be the correct one, if they
differ. That's why I need to be able to compare the text in column A to the
text in column B.

Any help is appreciated.
 
Hi!

When you say the two columns are supposed to be identical
does that mean cell A1 is supposed to be identical to cell
B1?

Or, does it mean the value in cell A1 is supposed to have
an identical value anywhere in col B?

Biff
 
The contents in A1 are supposed to be identical to B1, A2 is supposed to be
identical to B2, etc.
 
Ok, then in C1 enter this formula and copy down as needed:

=EXACT(A1,B1)

This will return either TRUE or FALSE.

Note that EXACT means just that! And since you said that
both columns of data come from separate sources it is
possible that even though they may look exactly the same,
there may be unseen characters like spaces, tabs or line
feeds that make them not identical.

If you do not need to be as specific as EXACT, you could
use: =A1=B1. This will not distinguish from things like
upper case and lower case.

Biff
 
Hi

Try this Exact(a,b) it will return true or false-- mind you it is case
sensitive

Regards

Sam
 
To compare two colums of text data, I would use a
function. I would use an IF function with a formula such
as "cellA = cellB" with 1 for false and 0 for true.

I would add a new column, and copy the function into
each row of the column where the data to be compared is
present. Below the text data, at the bottom of the
function colunm, add an IF function to check on the sum of
the column, if it is > 0, then at least one of the values
is different.

This will work only when the text matches exactly in every
regard.
 
Back
Top