Aug
26

How to compare two columns in Excel for matches and differences

Comparing columns in Excel is something that we all do once in a while. Microsoft Excel offers a number of options to compare and match data, but most of them focus on searching in one column. In this tutorial, we will explore several techniques to compare two columns in Excel and find matches and differences between them.

How to compare 2 columns in Excel row-by-row

When you do data analysis in Excel, one of the most frequent tasks is comparing data in each individual row. This task can be done by using the IF function, as demonstrated in the following examples.

Example 1. Compare two columns for matches or differences in the same row

To compare two columns in Excel row-by-row, write a usual IF formula that compares the first two cells. Enter the formula in some other column in the same row, and then copy it down to other cells by dragging the fill handle (a small square in the bottom-right corner of the selected cell). As you do this, the cursor changes to the plus sign:

Copy the formula down to other cells to compare two columns in Excel

Formula for matches

To find cells within the same row having the same content, A2 and B2 in this example, the formula is as follows:

=IF(A2=B2,"Match","")

Formula for differences

To find cells in the same row with different content, simply replace "=" with the non-equality sign:

=IF(A2<>B2,"No match","")

Matches and differences

And of course, nothing prevents you from finding both matches and differences with a single formula:

=IF(A2=B2,"Match","No match")

Or

=IF(A2<>B2,"No match","Match")

The result may look similar to this:
A formula to compare 2 columns for matches and differences in each row

As you see, the formula handles numbers, dates, times and text strings equally well.

Example 2. Compare two lists for case-sensitive matches in the same row

As you have probably noticed, the formulas from the previous example ignore case when comparing text values, as in row 10 in the screenshot above. If you want to find case-sensitive matches between 2 columns in each row, then use the EXACT function:

=IF(EXACT(A2, B2), "Match", "")
Comparing two lists for case-sensitive matches in the same row

To find case-sensitive differences in the same row, enter the corresponding text ("Unique" in this example) in the 3rd argument of the IF function, e.g.:

=IF(EXACT(A2, B2), "Match", "Unique")

Compare multiple columns for matches in the same row

In your Excel worksheets, multiple columns can be compared based on the following criteria:

  • Find rows with the same values in all columns (Example 1)
  • Find rows with the same values in any 2 columns (Example 2)

Example 1. Find matches in all cells within the same row

If your table has three or more columns and you want to find rows that have the same values in all cells, an IF formula with an AND statement will work a treat:

=IF(AND(A2=B2, A2=C2), "Full match", "")
Finding rows that have the same values in all columns

If your table has a lot of columns, a more elegant solution would be using the COUNTIF function:

=IF(COUNTIF($A2:$E2, $A2)=5, "Full match", "")

Where 5 is the number of columns you are comparing.

Example 2. Find matches in any two cells in the same row

If you are looking for a way to compare columns for any two or more cells with the same values within the same row, use an IF formula with an OR statement:

=IF(OR(A2=B2, B2=C2, A2=C2), "Match", "")
Finding matches in any two cells in the same row

In case there are many columns to compare, your OR statement may grow too big in size. In this case, a better solution would be adding up several COUNTIF functions. The first COUNTIF counts how many columns have the same value as in the 1st column, the second COUNTIF counts how many of the remaining columns are equal to the 2nd column, and so on. If the count is 0, the formula returns "Unique", "Match" otherwise. For example:

=IF(COUNTIF(B2:D2,A2)+COUNTIF(C2:D2,B2)+(C2=D2)=0,"Unique","Match")
Compare several columns and find matches in any two cells in the same row.

How to compare two columns in Excel for matches and differences

Suppose you have 2 lists of data in Excel, and you want to find all values (numbers, dates or text strings) which are in column A but not in column B.

For this, you can embed the COUNTIF($B:$B, $A2)=0 function in IF's logical test and check if it returns zero (no match is found) or any other number (at least 1 match is found).

For instance, the following IF/COUNTIF formula searches across the entire column B for the value in cell A2. If no match is found, the formula returns "No match in B", an empty string otherwise:

=IF(COUNTIF($B:$B, $A2)=0, "No match in B", "")
Compare two columns in Excel for matches

Tip. If your table has a fixed number of rows, you can specify a certain range (e.g. $B2:$B10) rather than the entire column ($B:$B) for the formula to work faster on large data sets.

The same result can be achieved by using an IF formula with the embedded ISERROR and MATCH functions:

=IF(ISERROR(MATCH($A2,$B$2:$B$10,0)),"No match in B","")

Or, by using the following array formula (remember to press Ctrl + Shift + Enter to enter it correctly):

=IF(SUM(--($B$2:$B$10=$A2))=0, " No match in B", "")

If you want a single formula to identify both matches (duplicates) and differences (unique values), put some text for matches in the empty double quotes ("") in any of the above formulas. For example:

=IF(COUNTIF($B:$B, $A2)=0, "No match in B", "Match in B")

How to compare two lists in Excel and pull matching data

Sometimes you may need not only match two columns in two different tables, but also pull matching entries from the second table. Microsoft Excel provides a special function for such purposes - the VLOOKUP function. As an alternative, you can use more powerful and versatile INDEX & MATCH formulas.

For example, the following formula compares the product names in columns D and A and if a match is found, a corresponding sales figure is pulled from column B. If no match is found, the #N/A error is returned.

=INDEX($B$2:$B$6,MATCH($D2,$A$2:$A$6,0))
Comparing two lists in Excel and pulling matching data

For the detailed explanation of the formula's syntax and more formula examples, please check out the following tutorial: INDEX & MATCH in Excel - a better alternative to VLOOKUP.

If you don't feel very comfortable with this formula, then you may want to try the Merge Tables wizard - a fast and intuitive solution that can compare and match 2 tables by any column(s).

Compare two lists and highlight matches and differences

When you compare columns in Excel, you may want to "visualize" the items that are present in one column but missing in the other. You can shade such cells in any color of your choosing by using the Excel Conditional Formatting feature and the following examples demonstrate the detailed steps.

Example 1. Highlight matches and differences in each row

To compare two columns and Excel and highlight cells in column A that have identical entries in column B in the same row, do the following:

  • Select the cells you want to highlight (you can select cells within one column or in several columns if you want to highlight entire rows).
  • Click Conditional formatting > New Rule... > Use a formula to determine which cells to format.
  • Create a rule with a simple formula like =$B2=$A2 (assuming that row 2 is the first row with data, not including the column header). Please double check that you use a relative row reference (without the $ sign) like in the formula above.

A conditional formatting rule to highlight matches in each row

To highlight differences between column A and B, create a rule with the formula =$B2<>$A2
A conditional formatting rule to highlight differences in each row

If you are new to Excel conditional formatting, please see How to create a formula-based conditional formatting rule for step-by-step instructions.

Example 2. Highlight unique entries in each list

Whenever you are comparing two lists in Excel, there are 3 item types that you can highlight:

  • Items that are only in the 1st list (unique)
  • Items that are only in the 2nd list (unique)
  • Items that are in both lists (duplicates) - demonstrated in the next example.

This example demonstrates how to highlight items that are in one list only.

Supposing your List 1 is in column A (A2:A6) and List 2 in column C (C2:C5). You create the conditional formatting rules with the following formulas:

Highlight unique values in List 1 (column A): =COUNTIF($C$2:$C$5, $A2)=0

Highlight unique values in List 2 (column C): =COUNTIF($A$2:$A$6, $C2)=0

And get the following result:
Comparing 2 lists and highlighting unique entries in each list

Example 3. Highlight matches (duplicates) between 2 columns

If you closely followed the previous example, you won't have difficulties adjusting the COUNTIF formulas so that they find the matches rather than differences. All you have to do is to set the count greater than zero:
Highlighting matches between 2 columns

Highlight matches in List 1 (column A): =COUNTIF($C$2:$C$5, $A2)>0

Highlight matches in List 2 (column C): =COUNTIF($A$2:$A$6, $C2)>0

Example 4. Built-in rule to compare 2 lists and highlight duplicates or uniques

If you are one of those power users who mostly rely on functions and formulas, you may have missed this amazingly simple way to compare two columns in Excel :)

  • Select two lists you want to compare. If they include different numbers of cells or are located in non-adjacent columns, select the first list, press and hold the Ctrl key, and then select the second list.
  • On the Home tab, go to Conditional Formatting > Highlight Cells Rules > Duplicate Values.
  • Select either Duplicate or Unique from the left-hand side drop-down list, and choose the desired format from the right-hand side drop-down. If you are not happy with any of the predefined formats, click Custom format... and set the Font or Fill color to your liking.
  • Click OK and you are done!

Built-in rule to compare 2 lists and highlight duplicate or unique values

Highlight row differences and matches in multiple columns

When comparing values in several columns row-by-row, the quickest way to highlight matches is creating a conditional formatting rule, and the fastest way to shade differences is embracing the Go To Special feature, as demonstrated in the following examples.

Example 1. Compare multiple columns and highlight row matches

To highlight rows that have identical values in all columns, create a conditional formatting rule based on one of the following formulas:

=AND($A2=$B2, $A2=$C2)

or

=COUNTIF($A2:$C2, $A2)=3

Where A2, B2 and C2 are the top-most cells and 3 is the number of columns to compare.

Highlighting rows that have the same values in several columns

Of course, neither AND nor COUNTIF formula is limited to comparing only 3 columns, you can use similar formulas to highlight rows with the same values in 4, 5, 6 or more columns.

Example 2. Compare multiple columns and highlight row differences

To quickly highlight cells with different values in each individual row, you can use Excel's Go To Special feature.

  1. Select the range of cells you want to compare. In this example, I've selected cells A2 to C8.

    Select the range of cells you want to compare.

    By default, the top-most cell of the selected range is the active cell, and the cells from the other selected columns in the same row will be compared to that cell. As you can see in the screenshot above, the active cell is white while all other cells of the selected range are highlighted. In this example, the active cell is A2, so the comparison column is column A.

    To change the comparison column, use either the Tab key to navigate through selected cells from left to right, or the Enter key to move from top to bottom.

    Tip. To select non-adjacent columns, select the first column, press and hold Ctrl, and then select the other columns. The active cell will be in the last column (or in the last block of adjacent columns). To change the comparison column, use the Tab or Enter key as described above.
  2. On the Home tab, go to Editing group, and click Find & Select > Go To Special… Then select Row differences and click the OK button.
    Select Row differences and click the OK button.
  3. The cells whose values are different from the comparison cell in each row are highlighted.If you want to shade the highlighted cells in some color, simply click the Fill Color icon on the ribbon and select the color of your choosing.
    To shade the highlighted cells in some color, click the Fill Color icon on the ribbon.

How to compare two cells in Excel

In fact, comparing 2 cells is a particular case of comparing two columns in Excel row-by-row except that you don't have to copy the formulas down to other cells in the column.

For example, to compare cells A1 and C1, you can use the following formulas:

For matches: =IF(A1=C1, "Match", "")

For differences: =IF(A1<>C1, "Difference", "")

To learn a few other ways to compare cells in Excel, please see How to compare strings in Excel.

For more powerful data analysis, you may need more sophisticated formulas and you can find a few good ideas in the following tutorials:

Formula-free way to compare two columns / lists in Excel

Now that you know Excel offerings for comparing and matching columns, let me demonstrate you an alternative solution that can compare 2 lists with a different number of columns for matches (duplicates) and differences (unique values).

Ablebits Duplicate Remover for Excel can search for identical and unique entries within one table as well as compare two tables residing on the same sheet or in 2 different worksheets / workbooks.

For the purpose of this article, we will be focusing on the second feature, which is called Compare Two Tables and is specially designed for comparing two lists by any column(s) that you specify. The comparison of two data sets by several columns is a real challenge both for Excel formulas and conditional formatting, but this tool handles it with ease.

Compare 2 lists by several columns in 6 quick steps

Supposing you have 2 tables of data and you want to find duplicate rows based on 3 columns - Date, Item and Sales:
Two tables to be compared by 3 pairs of columns

Step 1. Assuming that you have the Duplicate Remover for Excel installed, select any cell within the 1st table, and click the Compare Two Tables button on the ribbon to start the wizard. This button resides on the Ablebits Data tab, in the Dedupe group.
Click the Compare Two Tables button to start the wizard.

Step 2. The wizard picks the entire table and suggests to create a backup copy of the original table, just in case. So, simply make sure your 1st table is selected correctly and click Next.
Make sure the first table is selected correctly and click Next.

Step 3. Select the 2nd table by using the standard Select range icon Select range icon. If both tables reside in the same workbook and have similar column names, there's a great chance that the second list will be fetched automatically as well.
Select the second table to be compared to the first one.

Step 4. Select whether to search for matches or differences:

  • Duplicate values - look for matches, i.e. items that exist in both tables.
  • Unique values - look for differences, i.e. items that are in Table 1 but not in Table 2.

In this example, we select Duplicate values and click Next.
Select whether to search for matches or differences.

Step 5. This is the key step where you select the column pairs you want to compare in 2 tables. In this example, we are comparing 3 columns - Date, Item and Sales.

For the wizard to find the matching columns automatically, click the Auto Detect button in the upper-right corner. If the columns have different names in both tables, you might need to select the right column manually by clicking the little black arrow next to the Table 2 column on the right-hand side:
Select the pairs of columns to be compared in 2 tables.

Step 6. In the final step, you choose how to deal with the found items and click Finish.

The following two options deliver the results comparable to Excel formulas and conditional formatting that we've discussed earlier in this tutorial:

  • Add a status column - adds a new column with "Duplicate" or "Unique", like Excel IF formulas do.
  • Highlight - shades duplicate or unique rows like an Excel conditional formatting rule.

In addition, you can choose to delete the duplicate entries, move or copy to another worksheet, or just select the found items.

In this example, I've decided to highlight duplicates in the following color:
Choose how to deal with the found duplicate items.

And got the following result in a moment:
Duplicate rows are highlighted.

If we chose Add a status column in the previous step, the result would look as follows:

Duplicate rows are marked.

This is how you compare and match columns in Excel. If you are interested to try this tool, you are welcome to download a fully functional trial version. And if you like it, we will happily offer you the 15% off coupon code that we've created especially for our blog readers: AB14-BlogSpo. It works both for the Duplicate Remover tool purchased as a separate product and as part of Ultimate Suite for Excel.

If you want to have a closer look at the formulas discussed in this tutorial, feel free to download the Compare Excel Lists workbook. Thank you for reading and see you next week!

You may also be interested in:

188 Responses to "How to compare two columns in Excel for matches and differences"

  1. velan senthil says:

    it very useful

  2. Lauraflies says:

    This was extremely helpful and thorough. Thank you!

  3. Paul says:

    I've a problem in counting the number of appearing of the data in 2 adjcent cells in a same row.
    Say the row is filled with alphabet randomly, I want to find the times that "B" appears immediately adjacent to "A".
    Thank you.
    Paul

    • Fedor Shihantsov (Ablebits.com Team) says:

      Hello Paul,

      Please try the formula below for your task.

      =COUNTIF(A1:F1, "*AB*") + COUNTIF(A1:F1, "*BA*")

      Hope this helps.

  4. Rod says:

    I am wondering if possible to take column A make a match to the bestest (does not have to be 100% exact) match in column B and to say be able to copy that information back to where I want it to be. Doing some url links from data feed and testing idea's like this and hoping to come up with a better answer than doing it by hand. I got 519 rows in column A (menu name for links for website, etc) and 7546 rows in column B from data feed with the end to the links I want to make. Column A is say Women's Active Clothing Or Womens Active and Column B (has in the 7546 rows) a match like clothing & accessories > women > active (this is exact of how they look). I want to match them up then make a url out of it later like mysite.com/products/category/clothing & accessories > women > active to assign to menus like Women's Active Clothing. If any one has an idea please let me know. Am test trialing the software but yet not figured out or if possible to do some thing this hard

    • Hello, Rod,

      For us to be able to assist you better, please send us a small sample table with your data in Excel and include the expected result. Thank you.

      • HARI says:

        Need some help please. I have 3 separate cells, each ca contain variable data
        e.g. Cells A1 and A2 can contain one of the following P, p, pi, pe,F, f, -, untested, Cell A3 can contain P,p,F,f,-,untested - what I want as a result in A4 is - If A1 and A2 and A3 all contain P or p(i or e also)then ALL OK, IF A1 or A2 or both contain an F or f but A3 = P or p then A4 should read T OK but prob. If Ai and A2 have P,p,pi,pe but A3 is F then A4 should read T OK up to x-point. If A1,A2 and A3 all contain an F or f then A4 should read T F
        Hope you can help - Many Thanks

  5. avinash says:

    Thanks.. helpful

  6. Oscar says:

    Helpul excel functions

  7. E says:

    Thanks, the info was very helpful...

  8. BVKumar says:

    Very useful. Very through. Fantastic

  9. ram says:

    how to check column 1 caste oc; column 2 male or female
    how to count caste oc how many female and how many male ?

    • Hello Ram,
      It sounds like you need to add a Pivot Table. We assume your data look the following way:
      Count values in column 2 by values in column 1
      - Select your data, go to Insert tab in Excel and click on Pivot Table
      - Drag column 1 to Rows
      - Drag column 2 to Columns and to Values
      You will get a count for each oc the following way:
      Pivot table to count males and females

  10. Yulia says:

    Hi there, the article is very helpful, however I struggle with comparison where some empty cells are included.
    Your "Compare multiple columns for matches in the same row" Example 1 is what I was searching for, but it doesn't work if there are empty cells in between.
    Say A1= MARK, B1= MARK and C1 is empty, the function gives an error. How can I ignore those empty cells and still the answer to be "match".

    Thanks!

    • Hello Yulia,
      If blanks occur only in one of three values in the same row, please use the following formula:
      =IF(AND(IF(AND(NOT(ISBLANK(A1)),NOT(ISBLANK(B1))), A1=B1, TRUE), IF(AND(NOT(ISBLANK(A1)),NOT(ISBLANK(C1))), A1=C1, TRUE), IF(AND(NOT(ISBLANK(C1)),NOT(ISBLANK(B1))), C1=B1, TRUE)), "Full match", "")

      If you may have blanks in two of three values in the same row, please use this formula instead:

      =IF(COUNTBLANK(A1:C1) > 1, "",IF(AND(IF(AND(NOT(ISBLANK(A1)),NOT(ISBLANK(B1))), A1=B1, TRUE), IF(AND(NOT(ISBLANK(A1)),NOT(ISBLANK(C1))), A1=C1, TRUE), IF(AND(NOT(ISBLANK(C1)),NOT(ISBLANK(B1))), C1=B1, TRUE)), "Full match", ""))

      • Yulia says:

        Hi Irina,

        actually I have found another option: =IF(AND(OR(A1=B1;B1="");OR(A1=C1;C1=""));"ok";"error")

        A little bit primitive, but for the purpose works good

        Thanks
        Yulia

  11. Joseph says:

    Hi, I need help with a formula. In my example, I am comparing dates between 2 columns (production dates), and I highlight only rows where the dates do not match. I wish to add to the existing formula, so that the comparison (and highlight) is not made if a third column is >1 (which would mean the order has already been produced). My intent is to focus on as-yet unproduced orders, and eliminate the highlight on orders already in stock.

    Thank you!

  12. Ali says:

    Hi all,
    I would appreciate your help with the following:
    I would like to compare two columns, let us say Column A and Column B, looking for duplicates. If a value in Column A has a match value in Column B, I would like to format the cells of the same duplicate value with the color (the colors are random and different for each match). This is if A12 = B30, the color will be red. And if A20 = B1, the color is green and so on.

    Regards,
    Ali

    • Hello Ali,
      I'm sorry, but there is no simple way to do this. You can have a custom tool developed for you, but as soon as there are over ten values that have duplicates, you can only use the color shades that may be difficult to differentiate.
      It may be better to create a conditional formatting rule to check duplicates of a particular value in column A and in column B, then change the rule to see the duplicates of the next value, and so on.

  13. imtiaz says:

    I need a mark to find duplicates in an excel sheet.

    The problem with the records are, they are not exactly the same.
    There is always one or more field(s) that differs from each other.
    I want to have an automatic way of recognizing this cases.

  14. gokul says:

    Please help me! I have 2 column a and b. "A" column have frutis information. "B" column have rates. The problem is a and b both have duplicate values. A have multiple time "orange". "B" have different rates sometime same rate. I have to find out does the orange has same rate all the time or different rate. If same rate than it has to display match if different rate. Than mismatch

  15. Herman Kengere says:

    Hi Irina Kindly give me your email so that I attach my illustrated problem.
    Thanks in advance.

  16. SPdahal says:

    I need Example 3. Highlight matches (duplicates) between 2 columns for bank Reconciling because this problem

    Column A Column B
    2 match 2 Match
    2 match

    this case only one 2 match

  17. Mohanraj Mani says:

    Great, Thanks a lot.

  18. khan says:

    Hi Dear
    I have a problem to compare figure in the same row. How can i find out the row if the difference between them is more than double.

  19. Rama says:

    I want to keep index data with two columns (A, B) and find word in A in C column.. if A matches in C, add B in D column. Please help me with this.

    Example:
    Column A
    New Jersey
    Texas
    New YORK

    Column B:
    NJ
    TX
    NYC

    Column C:
    New Jersey
    New Jersey
    New York
    New Jersey
    Texas
    Texas
    New York
    New Jersey

    Result should be in Column D:
    NJ
    NJ
    NYC
    NJ
    TX
    TX
    NYC
    NJ

  20. Rama says:

    State Code
    New Jersey NJ
    New York NYC
    Texas TX

    If state is found in any where in the sheet.. the result should come in another column with state code.

    State State
    New Jersey
    New Jersey
    New Jersey
    New York
    Texas
    New York
    New Jersey
    Texas
    Texas
    New Jersey
    New Jersey
    New Jersey

  21. Mahesh says:

    Hi,
    I have 6 digit alphanumeric data in Column A and B. Both are not in order and in different series. Few numbers in column A and B are same. how to find out common numbers in both column with a color highlight.

    Thank you,

  22. Amit says:

    i have 2 columns a and b if the value of a and b column is "yes" the result should be displayed in c column as "resolved" but if either a or b has value no it should display as Followup,

    i was able to apply the formula in c column but when the value of a column or a and b column both becomes no it displayes as false not the Followup what part i m missing

    =IF(a:a="YES",IF(b:b="YES","Resolved","FOLLOWUP"))

  23. Liz says:

    I have two sets of data to compare: Column A to Column D, and Column B to Column E. How can I write one formula to look for matches or differences? For example:
    Column A Column B Column C Column D Result
    12345AA AEP 12345AA AEP True
    12345AB AEP

  24. Liz says:

    Sorry, I somehow posted before I was done writing..

    I have two sets of data to compare: Column A to Column D, and Column B to Column E. How can I write one formula to look for matches or differences? For example:
    Column A Column B Column C Column D Result
    12345AA AEP 12345AA AEP True
    12345AB AEP 12345SS HMA False

    I hope this makes sense.

    Thanks!
    Liz

  25. Ady says:

    Hi.. I have a data to sort.
    As the numbers are not in sequence in each coloumn,
    How can i make them in sequence to each other side by side.

    Eg:

    Column A Column B
    211 212
    212 214
    213 215
    214
    215

    What Im looking for is to sort column B data side by side with column A. I have 6000 numbers to sort right now.Thank you.

    What it should be Eg:
    Column A Column B
    211
    212 212
    213
    214 214
    215 215

  26. Deeba says:

    Hi I want to compare just first 10 digits of the two cells.What formula can I use.

  27. Alpesh says:

    I wann compare this two colum in One Colum

  28. SARAH says:

    Hi!

    I would like to check if the ask how to check two columns (one reference, one data) to another two columns even if they are not same in order. For example:
    1) WORK 1 2) WORK 2
    REFERENCE DATA REFERENCE DATA
    001 RED 005 YELLOW
    002 BLUE 001 RED
    005 YELLOW 002 PINK

    ** REFERENCE 001 AND 005'S DATA ARE MATCH WITH WORK 2 DETAILS.
    BUT FOR REFRENCE 002, DATAS ARE NOT MATCH WITH WORK 1 AND WORK 2

    Even if they are not in the same order, by matching the reference and the data, I need to have a formula to know what details are not match for Work 1 to Work 2.
    Please help me with this.
    Thank you!

  29. nikhil says:

    Hi,
    can you please tell me how to take the difference of dates in cases like:
    STARTTIME
    24-MAR-16 09.25.20.859619000 AM

    ENDTIME
    24-MAR-16 09.25.23.028557000 AM

  30. Rob says:

    Hello,
    I am struggling with how to compare values, and if there is a match, insert a new column. For example, sheet 1 has:
    Column A has server names, and will contain duplicates (column B contains application name, multiple app's can run on the same server)

    Another spreadsheet (sheet 2) has unique server names by Datacenter (1 Excel sheet for each datacenter). I planned on copy/paste it into column D on sheet 1. If there is a match between column A and D, add a value (the value would be the same each time, as I am pasting only datacenter 1, then datacenter2, etc.) for the Datacenter into column C.

    Hope that made sense, and thank you in advance!

    • Rob says:

      I think I found a useable way to get this done, but not ideal. I'll compare the values, if it matches, write MATCH in column C. Then just replace the word MATCH with the Datacenter I am running it for. After a few runs, I'll be done, since I will paste one DC at a time. :-)

  31. Kerry says:

    I need to sort column A where there is a duplicate number in red text. All numbers that don't have a duplicate red text number need to be removed.

  32. sameer says:

    Thank you very much, these notes are really good and helpful for analysis.

    Best,
    Sameer

  33. shohan says:

    Thanks a TON!!!!!!

  34. Uma says:

    Hi ,

    I wanted to find similar occurrences of string between two columns, If Column 1 text=Marks , then i need to find how many 'marks' in column 1 have 'pass' or 'fail' in column 2.

  35. Uma says:

    Hai

    i have a big doubt to find the duplicate values and match the duplicate data's actual values

  36. Dawn says:

    I'm trying to find how to write a formula for this scenario (pseudocode as follows): If Status="A" and dueDate contains a value, OR if Status = "C" (No dueDate info needed in this part), then it's True. Is there a way to have a formula order similar to If(OR((Status="C"),AND(Status="A",dueDate""),True, False))), or am I completely off track? Thank you in advance!

  37. s.stanly john peter says:

    how to get the sum for the folowing values in excel with out draging the mouse
    ColumnA ColumnB
    1234
    1234
    1234
    1234
    1234

  38. s.stanly john peter says:

    how to get the sum for the folowing values in excel with out draging the mouse
    ColumnA ColumnB
    1234 05:00
    1234 03:30
    1234 05:00
    1234 03:30
    1234

  39. s.stanly john peter says:

    how to get the sum for the folowing values in excel with out draging the mouse
    ColumnA ColumnB ColumnC
    1234 05:00
    1234 03:30
    1234 05:00
    1234 03:30
    1234 05:00
    1234 03:30 =Totalhrs?
    5678 05:00
    5678 03:30
    5678 05:00
    5678 03:30
    5678 05:00
    5678 03:30 =Totalhrs ?

    I want total hrs of 1234 and 5678 in columnC with some formulas urgent please

  40. Lisa says:

    I would like to compare two different spreadsheets. The first spreadsheet has several names that are the same but with different criteria. Ex:

    First column will have:
    John Smith
    John Smith
    John Smith
    John Smith
    Peter Tom
    Peter Tom
    Peter Tom
    Charlie Jones
    Charlie Jones

    Second column next to John Smith will have
    Apples
    Oranges
    Pears
    Bananas

    On another worksheet I have John Smith then next to it Pears. What I want to do is to see if John Smith that has Pears is on the first worksheet.
    Can anyone assist me?

  41. Kumar says:

    Hi.. I would like to compare 2 different spread sheet data in excel. each spread sheet contains 15 columns and 1000 records. I would like to write a formula to know whether the spread sheet one data is matching with all the columns of spread sheet two or is there any change in each column. please let me know.

  42. Hamlet Mehrabian says:

    Hi, I need to show in a cell the number of rows that have value in any of the cells in it and give me the column titles.

    example CFGA
    3

    because: there were three rows in the celection that had value only in columns CF and GA out of celected 4 columns.

    Will greatly appreciate it.

  43. Uktam says:

    Hi can someone help me how i can compare two sheets columns and that compared cells has to be seen in other sheet. i consider it will very great i mean it may more visible

  44. Patrick kivale says:

    Thanks very informative content

  45. Rainer says:

    Sorry, that earlier post was accident :)

    Hi!
    How can I make Excel sheet which compares Game result to my quess? And then I get points depends how good was my quess.
    Here is small Example

    Result My quess Points
    0-1 0-2 4 winner right and one value right
    1-1 1-1 10 Both values right = 10 points
    1-1 2-1 0,5 One value right
    1-2 0-3 3 Winner right, both values wrong
    0-0 1-2 0 Both values wrong

  46. Ashique says:

    hi....
    I need a help to compare two sheets but it should compare the entire row only if there first column matches.
    for example:

    Sheet1
    Row ID Order ID
    32298 CA-2012-124891

    26341 IN-2013-77878

    25330 IN-2013-71249

    13524 ES-2013-1579342

    Sheet2
    Row ID Order ID
    32298 CA-2012-124891
    26341 IN-2013-77878
    25330 IN-2013-71249

    here suppose row number 2,4,6 are blank or u can say contains other data. But need to compare row only when rowID matches...
    32298==32298 but they are in different row numbers

  47. sathya says:

    row to row cheque the same the
    numbar

  48. Steve says:

    I've been searching for a solution to this, but have so far haven't found an answer.

    In a soccer league consisting of several matches there are a number of two differing outcomes to a specific criteria.

    Here's a summary:

    League and Result
    ASIA: East Asian Championship Won
    ASIA: East Asian Championship Lost
    ASIA: East Asian Championship Women Lost
    ASIA: East Asian Championship Women Won
    AUSTRALIA: Brisbane Premier League Won
    AUSTRALIA: Brisbane Premier League Lost
    AUSTRALIA: Brisbane Premier League Won
    AUSTRALIA: Brisbane Premier League Lost
    AUSTRALIA: Brisbane Premier League Lost
    AUSTRALIA: Brisbane Premier League Won
    AUSTRALIA: Capital Territory Won
    AUSTRALIA: Capital Territory Won
    AUSTRALIA: Capital Territory Won
    AUSTRALIA: Capital Territory Won
    AUSTRALIA: Northern NSW Lost
    AUSTRALIA: Northern NSW Won
    AUSTRALIA: Northern NSW Lost
    AUSTRALIA: Northern NSW Won
    AUSTRALIA: Northern NSW Lost
    AUSTRALIA: Northern NSW Won
    AUSTRALIA: Northern NSW Lost
    AUSTRALIA: Northern NSW Lost

    What I want to do is create a report that lists each league and counts the number of Wins and Losses in each:

    League Criteria
    ASIA: East Asian Championship Won 1
    ASIA: East Asian Championship Lost 1
    ASIA: East Asian Championship Women Lost 1
    ASIA: East Asian Championship Women Won 1
    AUSTRALIA: Brisbane Premier League Won 3
    AUSTRALIA: Brisbane Premier League Lost 3
    AUSTRALIA: Capital Territory Won 4
    AUSTRALIA: Northern NSW Lost 5
    AUSTRALIA: Northern NSW Won 3

    I've looked at Pivots, and that goes some of the way there. But I can't figure out how to count the number of wins and losses in each of the leagues.

    Many thanks :)

  49. Sateesh says:

    Its very good site, which is useful and saved my one week manual effort.

    Regards,
    Satish

  50. AZHAR says:

    Hi I have beeen stuck in a problem I have data with mulipt column with simlier values but different lenght =INDEX($B$2:$B$6,MATCH($D2,$A$2:$A$6,0))
    but problem is i have four columns withe common values in one two or three oe all four like your banan expmale so i want to extract the rspective values for common values in multiple columns how it will work tell me please or some other method

  51. mohamed says:

    I have 2 excel worksheets. 1st sheet contain 900 names with details in 9 columns.
    2nd sheet is with 600 names (which are available in above 900) but with different details in 6 columns.
    I want to merge the details of 2nd list of 600 with those details of 600 available in the 900 name list.
    How to do this.

  52. Maria N says:

    Hi,

    I have 1 spreadsheet with 4 separete text tables. Each table contains a code on the first column and a description on the second.

    How can I highlight the mtaching letters sequence or identical words on the second column (description) of two considered tables?

  53. kalpesh says:

    I have large amount of data,

    Example
    COL-A " PIPE SEAMLESS API 5L Gr. B PSL2 NACE+HIC 3/4"(20 MM) SCH 80 PLAIN END ASME B36.10M "

    COL B- " PIPE SEAMLESS API 5L GR B PSL2 NACE + HIC 0.75 SCH 80 PLAIN END ASME B36.10M "

    I want to find the difference in content of cell,
    e.g in example difference between COL-A & COL-B is {3/4"(20 MM) & 0.75}

    Can anyone help?

  54. Yel says:

    I read this article and its great but I haven't found solution to my problem.
    I need to compare every to cells in a column that belongs to same object in 2 rows.
    I mean for each object (out of many objects) I have 2 rows and multiple columns and for every each of this columns I need to compare every 2 cells (that are one row after another) to see if the data is the same, if not then I need to highlight the 2 cells.
    I hope someone can understand me and answer me. I need some condition or maybe to write a command in Macro.

  55. Tim says:

    I have a spreadsheet that needs to be alpha dominant where column A is a lower alpha character and column B wants to be a higher alpha character relative to column A.
    An example of this is.
    Column A Column B
    ABC DEF

    However, if the columns A and B values are flipped where it is not the correct output such as will be incorrect.
    Column A Column B
    DEF ABC

    I need a formula to weed out the lower alpha to higher alpha issue on a spreadsheet with thousands of rows.

    Thanks

  56. manoj says:

    kindly help me to assign the remarks of attendence as excellent, good or bad based on the student attendence. It will be mentioned in range as 95-99 as Excellent,90-94 as good, 85-89 as average and like.
    kindly reply

  57. Manish says:

    I've been using a column compare macro which gives me the data (which is there in column A but not in column b) into column C AND the data (which is there column B but not in column A) into column D. I'm trying to find out the formula used to make this macro.

    Thanks!

  58. n4dk03 says:

    Hi,

    your description is actually very clear and helpful,thanks a lot. But with my data set it didn´t work for some reason. I want to compare two columns with gene names to find genes which are in column A and in column B, so i tried your example "Example 3. Highlight matches (duplicates) between 2 columns" respectively "Example 2. Highlight unique entries in each list", but unfortunately no cells were marked although there are duplicates. Do you have any idea why this happened?

    Thanks a lot!!

  59. kadrleyn says:

    Thanks for tutorial. The comparing can be done with Excel Vba Codes .The compare process can be made with Excel Vba Worksheet.Countif Function .

    Two columns in different worksheets were compared in this template .Found different results as entire row were copied to second worksheet .
    Codes :
    "Dim stk, msb As Worksheet
    Set stk = Sheets("Page1")
    Set msb = Sheets("Page2")

    Application.ScreenUpdating = False
    sat = (msb.Range("A" & Rows.Count).End(xlUp).Row) + 1
    For i = 2 To stk.Range("A" & Rows.Count).End(xlUp).Row
    If WorksheetFunction.CountIf(msb.Range("A2:A" & msb.Range("A" & Rows.Count).End(xlUp).Row), stk.Cells(i, "A")) = 0 Then
    msb.Range("a" & sat).EntireRow.Value = stk.Range("a" & i).EntireRow.Value
    msb.Range("a" & sat).Interior.ColorIndex = 22
    sat = sat + 1
    End If
    Next
    ...
    "
    Template at :http://goo.gl/ZeOwa2

  60. Dallas > Please help says:

    # Name TYPE
    abcd Abbott Nails
    abcde Cost Comedy
    baco Lion Mane
    zhty Bear Paw
    zhty Bear Paw

    The above is a simplified version of my data however there are numerous rows and columns but overall I would like to identify unique values across columns and rows simultaneously by documenting it with a 1 as unique or a 0 as it occurred in previous rows across columns.

    # Name TYPE Nails Comedy Mane Paw
    abcd Abbott Nails 1 0 0 0
    abcde Cost Comedy 0 1 0 0
    abcde Cost Comedy 0 0 0 0
    baco Lion Mane 0 1 0 0
    baco Lion Mane 0 0 0 0
    zhty Bear Paw 0 0 0 1
    zhty Lion Mane 0 0 1 1

  61. Dallas > Please help says:

    That output looked funky so I wanted to clarify:

    Col. A = #
    Col. B = Name
    Col. C = TYPE

    Col.D = Nails
    with 1 and 0 in data which shows a 1 as a unique listing throughout the rows above and columns A – C.

    Col. E = Comedy with the same statement as above with 1’s and 0’s
    Col. F = Mane ….
    Col. G = Paw ….

  62. Dallas > Please help says:

    I have a product if statement but it’s not working properly

    see below

    =IF(SUMPRODUCT(($A$2:$A2=A2)*($B$2:$B2=B2)*($C$2:$C2=C2))>1,0,1)

    ….It’s not providing 0’s where there is repeat data across the columns based on the rows above. If it were working it would place a 0 rather than 1.

    Thank you Everyone!

  63. Sudeep says:

    Hi

    i need to compare one column to all the rows present in Second column.can someone answer?

  64. SANDEEP KUMAR says:

    USE THE FN EXACT.. FOR MATCHING TWO CLM

  65. Kashish says:

    Hey sir if I'm having 5 cells in 2 columns say column A and Column B.
    with entries like.
    Column A Column B
    1. B21 Rojer
    2. B11 Rojer
    3. A11 Adam
    4. A11 Adam
    5. C22 Chris
    6. C22 Chris
    How can I select the row 1 and row 2 which are having different code for same name Rojer

  66. jayesh says:

    Data validation list A =a1:a10
    Data validation list b =b1:b10

    link cell D1

    my problem is if selected list from List A or List B cell D1 change automatically any formula or any solution

  67. Boza says:

    Somebody to help me....
    Dear all,
    I have a huge problem...
    I have two rows A and B,
    Values in column A (3,4,4,5,5,6) in column B (3,3,4,5,6,6), I wont to compare this two column
    3 with 3 nothing
    4 with 4 nothing
    4 with x 4
    5 with 5 nothing
    5 with x 5
    nad reverse (if you dont have in column A, have in column B) also to be in column C.
    If you understan (match just once number by number), if aleready match to give me value.
    Tnks a lot, to all.

  68. Jonathon says:

    if column A has names and column D has dates. Is there a way to highlight equal dates that belong to the same name?

  69. johnng says:

    Hello.. I now actually trying using Index match/IF function to try to index the value from “ColE” onto “ColB” , by matching “ColA” compare with “ColD”.

    For my eg.
    Shown below “Urr” got 3 different value in “ColE” how to I match and insert the three “Urr” with the different number
    result in “ColE” onto “ColA” with the same exact result number should appear in “ColB”???
    And “colA” “Usw” data still match with “ColD” “Usw”even is not in the same row?

    something like new data replace with original data orderly, plus without deleting original data if the data don not appear in new data.

    Eg.

    ColA
    Doman
    Urr
    Usw

    ColD ColE
    Doman 1234
    Urr 12345
    Urr 12345
    Urr 12346

  70. johnng says:

    Hi i currently using index and match function in excel, to auto match and index the value back, if i put a set of new data to compare with my original data.

    But however sometime a new data had a multiple result , how to i auto insert a row on the original data columns for the multiple result?

    this is my formula code : =INDEX($L:$L,MATCH($A:$A,$K:$K,0)) it could match and bring back the index value back i wanted ... but those with multiple result it only return back to the first result it show.

    regards istillanoob

  71. Alex says:

    Hi,
    Let say that column A has 2 cells and are as follow:
    A1 : 10
    A2 : 20
    And in column C there are 2 cells as follow:
    C1 : 10,20
    C2 : 20,10
    In cell B1 I want that it searches in A1 cell that is 10 and if the first number in column C is 10(that is C1 and not C2), it copies cell C1 in B1.

  72. Danta says:

    Hello,

    I want to know can we compare this type cells

    Cell A

  73. Danta says:

    Sorry,
    I posted before completing the question

    I want to compare likewise

    A B C
    Danta,Alex,John,Ryan Alex,Ryan,Danta,John True
    John,Alex,Ryan Alex,John,Danta False
    Michelle,Rob,Sean Michelle,Rob,Sean True

  74. Pip says:

    Afternoon,
    I want to put a conditional format in column B.
    I have a target number in column A and input Actual in B.
    I want a conditional format in B
    if the number is same as or above target in A then "fill" the cell otherwise no fill.

    610 0 - no fill
    1525 915 - no fill
    610 0 - no fill
    610 710 - fill
    610 610 - fill
    305 0 - no fill

  75. Avinash says:

    Thanx for such an informative article over excel,still struggling to find the solution ,Pl help if possible.
    I've two columns in which one column say B having exhaustive values,while in another say column A ,some values are missing.How to ascertain either through Vlookup,Countif or If,which values are missing. Here,it is to be noted that all data in A is in column B,but vice versa is not true. Just wanted to know missing data. Pl help in getting formula for the same.Total entries in column A is less than column B(vertically) Plzz..

    • Hello Avinash,

      If my understanding of the task is correct, you need to identify the values that are present in column B, but not in column A. If so, you can use the following formula:
      =IF(COUNTIF($A:$A, $B2)=0, "missing", "")

      Where B2 is the topmost cell with data, ignoring column headers.

      When you copy the formula down the column, the word "missing" will appear in the rows containing data in column B that do not appear anywhere in column A. To get a list of missing values, apply Excel's auto-filter, filter the formula column by "missing" and copy the filtered values in column B.

  76. Avinash says:

    Yes its working. Thank you so much. Grateful for the support.

  77. ivan says:

    Hi Guys,

    Need your advice.

    How to check duplication of two numbers in two different column, with the two number provided in different sequence order. sample as in below.

    Column A Column B Column C (result)
    1234 2341 A=B

  78. HS says:

    Dear,

    Need your advice.

    How to take data from two columns to another table ie. if we have two columns and having some data true and false so i need to separate true data and false data in another table

  79. michelle says:

    Hi, whuch formula should I use if I want to compare 2 excel sheets. 1 has been revised and 1 has no changed.
    please help!!!! Thank you

  80. Warren says:

    Hi, I have two columns.

    column A: a list of 60 different distinct computer hardware in every cell.

    Column B: over a thousand combination of not only including from 0 up to 10 computer hardware, but also have brand names in each cell.

    All I want to achieve is to display in column C what are those computer hardware A shown up in B, in the same row as in column B.

    Thank you for your time.

  81. Chandan says:

    Hello
    I have two excel sheets
    One sheets boys sheet mention name, gotra, year, qualification salary
    second sheets girls mention name, gotra, year, qualification salary
    how we can match it

  82. Ashok says:

    List 1 List 2
    1 a
    2 a
    3 b
    3 b
    1 a
    3 c
    1 d

    Hello, please help me in the above example. I want to check if list 1 and List 2 has same row values. Like first row is same as the fifth so row 3 and 4.

    WHat formula should I use.

  83. marc says:

    I need a formula to count how many times column A has a ON and NS that represents a CU in column B. In the case below ON and NS represent a total of 3 CU's in column B

    A B
    ON CU
    BC CU
    AB CU
    ON CU
    NS CU
    NS BA

    Eg. =+COUNTIFS(QtradePartners!B3:B136,"=ON",QtradePartners!B3:B136,"=NS",QtradePartners!C3:C136,"=CU") ... THIS IS NOT WORKING and I think it makes sense that it doens't work... Anyone help?

  84. Erika says:

    I have a Google spreadsheet with 50 separate titled sheets with one that I have labeled as Forms_Received. All sheets are different meetings that we have going on and I need to compare a column in all the sheets with the Forms_Received sheet and have a column in all the sheets marked with "Y" if a form was received on each of the sheets. I would prefer that the "Y" be an exact match from the column in the Forms_Received sheet, since it will have a linked document attached to the "Y". What formula should I use? If you need to see what I am talking about, please let me know.
    Thank you,

  85. Tamer says:

    Thanks a lot,
    It saved me couple of hours.

  86. jen says:

    I have 2 sheets. 1 has a column with 14 digit numbers representing products. The 2nd sheet has a column with 10 digit numbers also representing products. Product descriptions are different in each sheet. I want to verify the list of 10 digit numbers are included within the sheet with 14 digit numbers. Can you help? Thanks!

  87. Paul says:

    Hi- Thanks for your post. I have another requirement.
    I have two columns ex A and B. In col A is a list of employees and Col B is list of employees (kind of sub set of Col A), Col B can contain all the employees present in Col A, but if any employee left in this month then that employees name will be removed from Col B. Also Col B can contain new employees as well.

    So end of the month I want to run a report and show that Which all employees Of col A is present in Col B , list them in a new col C, and also Column C also should list out if any new employees names are found in column B and put that also in Column C.

    Can you help?

  88. Rishikesh Shetty says:

    Hello,
    I have two data sets (sheets), first columns in both the sheets have data that can be matched. Based on the first columns, I want to create a new data set having the expanded data for each of the columns.

    Thanks.

  89. E Sivakumar says:

    Hi ,

    How to compare two cells whether another cell contains same word,

    Location Code Description Location from part no Status
    LEAF SPRING FRONT REAR AXLE PARABOLIC SPRING FALSE

    Thanks

  90. Deepal says:

    I have some items and rates in one table, other table I need to type item name and get relevant rate to next column in same row Table1 Table2 Item. Rate. Item. Rate. A. 3. D. ? B. 4. A. ? C. 6. B. ? D. 4. E. 1. .... Z. 4.

  91. prabhakar says:

    Thanx. it helped me.

  92. DrewM says:

    Hello,
    I am trying to do a comparison between 2 columns for values only. In one column, the value is 13 while the other I am comparing it to is 13.0. None of the methods I have tried return a match.
    Is there a way to compare for a match in value of the two without having to reformatting the columns to match?
    Thank you in advance for any help that can be provided.

  93. raji says:

    how to convert excel data to note pad text transpose (T). and need to add some ad some special character with the text

  94. sn_cathy says:

    Very helpful. Thanks so much!

  95. Kim says:

    I need a formula to count how many times a specific range of numbers occurs twice in a row.

    Example: how many times a number between 1 and 9 occurs at the same time in column C and D

    1, 7, 9, 14, 20, 27
    1, 3, 4, 5, 14, 21,
    2, 3, 4, 17, 22, 23
    4, 5, 7, 8, 20, 24
    16, 17, 18, 20, 21, 22

    The answer is 2 times

    I thought I could use:
    =COUNTIF(C1:C379,"<=9") + COUNTIF(D1:D379,<=9")

    But it is adding the number of times the range occurs in column c to the number of times the range occurs in column D. What I need is the number of times the range occurs in column C and D within the same row, or in other words, at the same time.

    Thanks!

  96. Joseph says:

    Hello good evening,

    I need small help. So I need to get how many same numbers repeats in Column A that matches same value in column B. Example How many times 38692 repeats in column A and has value of $5 in column B? Can anyone help me with that please
    A B
    38770 $10.00
    38692 $5.00
    38692 $5.00
    38692 $5.00
    38692 $10.00
    38769 $10.00
    38692 $5.00
    38692 $5.00
    38692 $10.00
    $0.00
    $0.00
    38694 $10.00
    $0.00
    38694 $10.00
    $0.00

  97. Yasir says:

    Is it possible to compare for certain values two different sheets of same Ms Excel file?

  98. Bill says:

    Excellent website, thanks.

  99. Albourn says:

    I would like to know how to compare a range "A1" of file names with a directory and return the date the file was last save to a each matching cell in range "B1"

  100. Baiju says:

    Need a formula based on below criteria:
    I have two cells, A and B,
    if the difference btw A & B is less than 6 or equal to 6, "No Change"
    if greater than 6 and less than 9, "Slight Change"
    if greater than 10 "Significant Change"

    Also the formula should override the difference with positive numbers, even the B is larger than A, vice-versa

    Please help!!

  101. Glenroy Carty says:

    As a step in a bank reconciliation, I am comparing two list of $amt. I do have a unique identifier in one list but not the other, just $ values.
    I want to compare the $values and find a "unique" match. Meaning, say I have $155 twice in list 1, three times in list 2.
    Is there a way to id the match 2?
    With a unique identifier in both list, two column match with condition formatting would work fine.
    It a large volume of data, please help!

  102. kevin18roy says:

    I need help writing a formula to find matches between a column in SHEET1 and a column in SHEET2. Goal is to get "Match" inserted into Column B, SHEET1 if there is a match between Column A and Column B.

    I tried:

    =IF(A2=$SHEET2$,B2,"Match","") but this didn't work. Can someone help me out please!

    Data:

    Column A, SHEET1
    12AB1250
    12AB1251
    12AB1252

    Column A, SHEET2
    12AB1250
    12AB1251
    12AB1252
    12AB1253
    12AB1254
    12AB1255

    Thanks in advance!

  103. allan says:

    Good day
    I`m a marine engineer.I am just creating a worksheet where if a parameter in column F is greater than a parameter in columnn I by 0.03(P4>Pd>0.03),A separate column say H has to highlight each row as Abnormal with cell bgrnd as red.Would you please help me on this
    Thanks in advance
    Allan

  104. satish Gummanur says:

    i want add the data with different uniqe item below following table
    item data
    1 4
    2 3
    1 2
    3 2
    2 3
    1 1

  105. Jamsheed says:

    how to Compare table columns in excel
    for example
    Table -1
    Col A; Col B; Col C;
    Roll No. Std. Name Result 1 semester (total Marks)
    1 A 50
    2 B 40
    3 C 55

    Table -2
    Col A; Col B; Col C;
    Roll No. Std. Name Result 2 semester (total Marks)
    2 B 45
    4 D 60
    1 A 60
    3 C 50

    I Want to Result like that

    Table -1 Table-2
    Col A; Col B; Col C; Col D; Col E; Col F;
    Roll No. Std. Name Result S-1 Roll No. Std. Name Result S-2
    1 A 50 1 A 60
    2 B 40 2 B 45
    3 C 55 3 C 50
    4 D 60

    Could you described please how i could solve this as Table 2 match with table 1 and sort and place the record on same row
    thanks

  106. Sourish says:

    Hi, kindly help me derive a proper formula for this problem. I am using two sheets Sheet 1 & Sheet 2 in excel 2013. I created a drop down value (1-15 & 1-15) in the first sheet using data validation to derive two numbers in two different cells. In the second sheet I have created variables (with 1-15 in one cell and 1-15 in another cell) to derive a result in the third column). Say, in the first sheet I have one column no. of factories (1-15) & No of Managers (1-15). In the second sheet I have created the variable; No. of Factories, No of Manager & in the third row their Operating hours:

    No of Factories: 1/2/3/4/5/....
    No of Managers: 1/2/3/4/5/....
    No of Operating hours: 8 (in case 1,1), 15 (1, 2), etc.

    Now in the first sheet I want to use the drop down values to enter what i want to know and get the result using a formula.

    Kindly help me with this.

  107. Karthik says:

    Hello I have 10 values in Col A and 3 values in Col B. I want to highlight only values that match col A with Col B and mark others in a diff color . How do i do it?

    Col A Col B
    1 1
    2 6
    3 9
    4
    5
    6
    7
    8
    9
    10

    Col A Col B
    1 1 Match
    2 No match
    3 No match
    4 No match
    5 No match
    6 6 match
    7 No match
    8 No match
    9 9 match
    10 No match

  108. boladale says:

    Excellent resource. I have two worksheets. one with 25,000 rows and the other with 63,000 rows and i want to find out the complete match of sheet2 to sheet 1, the ones without any match and others with at least 90% match. please how do i go about this. thank you

  109. GARRY says:

    not working the below formula in excel 2016, please guide if any changes on this?

    =IF(COUNTIFS($CU2:$CU59862,CU2, $CA2:$CA59862,CA2, $FL2:$FL59862,FL2, $DA2:$DA59862,DA2, $DV2:$DV59862,DV2) >1, "DUPLICATE ROW","")

  110. Gunsannie says:

    Hi,
    I have an sheet with columns from January to December where people make contributions on monthly basis. A person's contribution is the same through out the year.

    I would want a formula that shows if someone is contributing the same figure throughout the year or not, kind of like "True" and "False" formula but it should be checking in all the columns thus January-December and not just two columns whose formula I know is =A2=B2

    Thanks.

  111. Kostis says:

    HELP!

    Would you please help me?

    It is really important.

    What i want to do is this

    compare columns for any two or more cells with the same values within the same row and hightlight individual rows after matching

    I have 20 different columns that i need to compare for any two or more duplicate cells among them

    How can i do that with the simplest way?

    Thank you

  112. Shibu says:

    Hi, I need to copy data from one cell to another on daily basis
    Example,
    A1 : =TODAY() //Changes Daily
    B1 : =SUM(B2:B10) //Changes Daily

    I need the B1 value to be copied on C1
    Next day B1 value to be copied on C2
    Next day B1 value to be copied on C3 and so on...

    Waiting for your support
    Thanks in advance

  113. Jason says:

    I need some help.
    I am using vlookup to draw information from sheets A and B and then compare them side by side on Sheet C. The values happen to be in time format. I need to have a formula (or a quick system) to highlight the the cells so that I can quickly spot the different in the times and then correct them. The spreadsheet that I am using is already full of useful conditional formatting and so would really like it to just appear a different colour so that it gets my attention.

    Any suggestions much appreciated

  114. Junaid says:

    I am facing an issue of 10,000 row items contains data for visits.

    data contains same name but different start date and end date

    Shop Name Opening End
    CRUSH TRUCKING STATION 12-May-11 22-Dec-14
    SUPERIOR II FILLING STATION 11-Dec-13 14-Mar-14
    INDUS FILLING STATION 13-Dec-13 21-Feb-14
    INDUS FILLING STATION 21-Feb-14 17-Oct-14
    SUPERIOR II FILLING STATION 14-Mar-14 23-Oct-14
    INDUS FILLING STATION 17-Oct-14 25-Jan-15
    SUPERIOR II FILLING STATION 23-Oct-14 16-Jan-15
    SUPERIOR II FILLING STATION 16-Jan-15 08-May-15

    Is there any solution for above to adjust columns in start and end date in same shop name

  115. Beshoy says:

    Hi
    I need to make filter for unique value that created by multi user once per month per user than we need to calculate the QTY of the unique number per user

    Example for my Question:

    transaction_date Value User_NAME
    --------------------------------------------------
    1/1/2017 1222889205 MarK
    --------------------------------------------------
    2/1/2017 1222889205 Mac
    --------------------------------------------------
    4/1/2017 1254879863 Eva
    --------------------------------------------------
    21/2/2017 1225478962 Jake
    --------------------------------------------------
    4/5/2017 1254879863 Eva
    --------------------------------------------------
    5/5/2017 1254879863 Eva
    --------------------------------------------------
    1/6/2017 1254793658 Mac
    --------------------------------------------------
    1/6/2017 1254793658 Jake
    --------------------------------------------------
    6/6/2017 1254793658 Eva
    --------------------------------------------------

    **my Solution

    Month user Count for uniqe value
    --------------------------------------------------
    jan MarK 1
    Mac 1
    Eva 1
    -----------------------------------------------
    Feb JaKe 1
    ---------------------------------------------
    May Eva 1
    ----------------------------------------------
    Jun Mac 1
    JaKe 1
    Eva 1
    ---------------------------------------------

    Appreciate your support thanks

  116. Beshoy says:

    any feedback

  117. Jack says:

    Hi,

    Hopefully someone can understand what I am trying to do here.

    I am currently going through some spreadsheet files and I would like to find case based non-duplicates e.g.

    Column A Column B
    Row 1 Harry Potter Ron Weasley
    Row 2 harry potter Ron Weasley

    Basically I am looking for true non-duplicates where the case of the text is concerned, the above example using the method I am currently using (Conditional formatting and Highlight duplicate values) will mark the above A1&A2 example as a duplicate even though the case being different, I would like a solution to mark the A1&A2 entry as a non duplicate by any visual method to differentiate from an actual true duplicate entry e.g. B1&B2, note I do not want to manipulate the data to become true duplicates just want to highlight the case differences.I'm cross examining two Rows with about 40-50 Columns, in a multitude of files.

    Is what I am trying to achieve possible?

    Any and all help will be appreciated.

    Kind Regards
    Jack

  118. Brett says:

    Hello, I have been trying pull some matching data with little luck. I have 2 data sets 1 with demographic information and one with home sales information. Both have addresses I have broken down by: home number, direction,street name. These data sets are on 2 different sheets. How do I find matching: home number, direction, street name on each sheet? Hopefully that makes sense.

  119. Segun says:

    Hello.
    I need help on this issue. I wan to compare values of 2 columns. These values, even though they same, are not necessarily arranged in same order or may not even be of same string, eg.

    Jason Paul Macaulay Macaulay Paul
    J P Macaulay Jason Paul Macaulay
    Macaulay Jason Jason Paul Macaulay
    Macaulay Paul J P Macaulay

  120. Segun says:

    Hello,

    I need help on this issue. I want to compare values of 2 columns. I want a visual marker that will highlight (or mark as a duplicate) as long as any value of one column is contained in the other column.

  121. Segun says:

    Hello,

    I need assistance with this. I want to compare values of 2 columns. I want a visual marker that will highlight (or mark as a duplicate) as long as any value of one column is contained in the other column.

  122. Nicola Haycock says:

    I have a spreadsheet with over 100000 service name entries, however the service name can be named slightly different on several rows. I want to know if there is a formula which can highlight any mis matches in column B And C. For example the service is APERTURE but I can be known as APERTURE-CONT or APERTURE-UAT, however the owners name is different. I don't fancy going through all 10000 lines so was hoping there may be a formula that can highlight this
    SERVICE Owner First Name Owner Last Name
    APERTURE JOE BLOGGS
    APERTURE-CONT JOE BLOGGS
    APERTURE-UAT DERREN YOUNG

  123. Earl says:

    Need help,
    I'd like to be able to compare two cells with unique strings
    Ex. A1 = xyz0_ok_hmu1-ty
    B1 = ok1_ty
    I want it to be able to recognize that it is similar to a minimum of 2 ordered letter matches and be highlighted as "similar". If it is able to ignore multiple delimiters, that would be cool too.

  124. Melika says:

    Thanks so much for this TA; this just saved me a LOT of time!

  125. Star says:

    I'm trying to pull information from one spreadsheet into another, where the combination of two cells of data in each spreadsheet match exactly.
    Each spreadsheet contains two columns that contain the exact same data:
    Spd 1 - Column D> Work Order
    Spd 1 - Column M> Contract Unit Name

    Spd 2 - Column I> Work Order
    Spd 2 - Column Q> Contract Unit Name

    Spd 2 - Col VInvoiced Amt

    So where Spd 1, Col D and Col M = Spd Col I and Col Q, Import the value in Col V into Spd 1 Col O (Invoiced Amt)

    Data sample:
    Spd 1:
    Work Order Contract Unit Name
    E.724292.C.03 NRE-ROW AGENT BEA
    E.724292.C.03 NRE-ROW AGENT I
    E.731518.C.17 NRE-EXISTING RIGHTS LEVEL I
    E.731518.C.17 NRE-EXISTING RIGHTS LEVEL II
    E.732518.C.17 NRE-PROJECT COORDINATOR
    E.732518.C.17 NRE-TITLE SEARCH I

    Spd 2:
    Work Order Contract Unit Name Invoiced Amt.
    E.724292.C.03 NRE-ROW AGENT BEA 100.00
    E.724292.C.03 NRE-ROW AGENT I 75.00
    E.731518.C.17 NRE-EXISTING RIGHTS LEVEL I 125.00
    E.731518.C.17 NRE-EXISTING RIGHTS LEVEL II 175.00
    E.732518.C.17 NRE-PROJECT COORDINATOR 95.00
    E.732518.C.17 NRE-TITLE SEARCH I 200.00

    Do I use MATCH and INDEX and what would my formula look like?

  126. rm says:

    Hi All,

    Is it possible to compare my example below ? i need to compare column a + b in column c + d . my problem is on column a there is same values . please help me to create formulas if possible

    column a column b column c column d
    64571 75 64351 72.1
    64351 72.1 64571 75
    64571 73 64571 73

  127. Venu says:

    Hello There, i am kind of stuck with manipulating the excel worksheets.

    Scenario : Compare the cell text in two excel and replace range of value in sheet two with Values in Sheet one. Any guess how can we achieve this ?

    Scenario : Wanted to Pull the Values from Sheet one With all the Cells containing abc*(text)in sheet 1 and Copy the same Text and adjacent 3 Values from each row.

    Sheet 1 :

    row/col Col1 col2 col3 col4
    row1 123 abcde ghk 143

    Sheet 2 :

    row /col Col1

  128. Venu says:

    Hello There, i am kind of stuck with manipulating the excel worksheets.

    Scenario : Compare the cell text in two excel and replace range of value in sheet two with Values in Sheet one. Any guess how can we achieve this ?

    Scenario : Wanted to Pull the Values from Sheet one With all the Cells containing abc*(text)in sheet 1 and Copy the same Text and adjacent 3 Values from each row.

    Sheet 1 :

    row/col Col1 col2 col3 col4
    row1 123 abcde ghk 143

    Sheet 2 :

    row /col Col1 col2 col3 col4 col5
    row1 abcde ghk c143

  129. xyz says:

    Not understand the question dear.

    • venu says:

      Scenario1 :

      Check text "abc.AD" in sheet one, and return the next two cell values in sheet two.
      Note: The unique text is not in same column.

      Sheet 1 :
      Col10 Col11 Col13 Col14 col15 abc.AD Test NOP
      abc.AD Ext NOP
      abc.AD Int NOP
      Let me know if this helps

  130. HEMANT says:

    The spread sheet contain two column. In first column there is only the level i.e., Block, GP and Village and in another there is name contain of the respective Block, GP and Village. Let me know how I can manage the sheet that looks like in this manner as follows

    Block GP Village
    Block Name GP Name Village Name
    (if there is 10 village then it is shown in row wise)
    GP Name Village Name

  131. Walter says:

    Your page is excellent; your team is very helpful. I'm struggling with an issue. I have one sheet where I would like to highlight only the rows where values duplicated in the first column where the there are differing values in the second column. Duplicates are allowed in the first column. Duplicate values are allowed in the second column, also. However, duplicated values in the first column should always be paired with the same value in the second column. If not, then highlight all rows where first column contains the same duplicated value.

    Thank you.

    Col-A Col-B Format
    1 C Highlight Row
    1 C Highlight Row
    1 D Highlight Row
    2 A No Highlight
    2 A No Highlight
    3 E No Highlight
    4 C No Highlight
    5 A Highlight Row
    5 F Highlight Row

  132. meli says:

    Hi, I need help with a formula.

    The Formula for blank cell was very helpful Thanks.

    I have two formula with is correct answer, i combined the formula but there is error.

    Formula 1 -
    IF(OR(C3="",D3=""),"Single Punch",IF(AND(C3>A3,D3>=B3),"LATE",IF(AND(C3>A3,D3<B3),"LATE/EARLY",IF(AND(C3<=A3,D3<B3),"EARLY","PRESENT"))))

    Formula 2 -
    IF(AND(IF(AND(NOT(ISBLANK(C3)),NOT(ISBLANK(D3))), C3=D3, TRUE), IF(AND(NOT(ISBLANK(C3)),NOT(ISBLANK(D3))), C3=D3, TRUE), IF(AND(NOT(ISBLANK(D3)),NOT(ISBLANK(C3))), D3=C3, TRUE)), "Absent", "-")

    Would you Please help me find solution.

    Actual Time Log Time Remarks
    In Time Out Time In Time Out Time
    11:00:00 AM 8:30:00 PM 10:50:00 AM 8:40:00 PM PRESENT -
    11:00:00 AM 8:30:00 PM Single Punch (This should be absent) Absent
    11:00:00 AM 8:30:00 PM 11:30:00 AM 8:35:00 PM LATE -
    11:00:00 AM 8:30:00 PM 11:00:00 AM 7:00:00 PM EARLY -
    11:00:00 AM 8:30:00 PM 11:30:00 AM 5:35:00 PM LATE/EARLY -
    11:00:00 AM 8:30:00 PM 8:45:00 PM Single Punch Absent (This should be SP)
    11:00:00 AM 8:30:00 PM Single Punch Absent

    Please help

  133. PeshiyaBoy says:

    Hi Meli,

    As i can see it's time sheet of employee. I understand your query. But without sample sheet i am unable to put formula here. so share any short sample sheet fot add formula.

    • Meli says:

      In Time Out Time In Time Out Time
      11:00:00 AM 8:30:00 PM 10:50:00 AM 8:40:00 PM = PRESENT

      11:00:00 AM 8:30:00 PM - - = Single Punch (This should be absent) Absent

      11:00:00 AM 8:30:00 PM 11:30:00 AM 8:35:00 PM = LATE

      11:00:00 AM 8:30:00 PM 11:00:00 AM 7:00:00 PM = EARLY

      11:00:00 AM 8:30:00 PM 11:30:00 AM 5:35:00 PM = LATE/EARLY

      11:00:00 AM 8:30:00 PM 8:45:00 PM - = Single Punch Absent (This should be SP)

      11:00:00 AM 8:30:00 PM - - = Single Punch Absent

  134. Prason says:

    How to Salve This Prablem

    KS IN_Kirana Stores KSN Kirana Store New
    KS IN_Kirana Stores KSN Kirana Store New
    KS IN_Kirana Stores KSN Kirana Store New
    PS IN_Pan Shop PSA Paan Store
    PS IN_Pan Shop PSA Paan Store
    KS IN_Kirana Stores CSA Kirana Store New
    CS IN_Kirana Stores KSN Kirana Store New
    KS IN_Kirana Stores KSN Kirana Store New
    KS IN_Kirana Stores KSN Kirana Store New
    KS IN_Kirana Stores KSN Kirana Store New
    KS IN_Kirana Stores KSN Kirana Store New
    PS IN_Pan Shop KSN Paan Store
    CS IN_Cosmetic Store CSA Cosmetic Store

  135. TK says:

    Hi,

    Below is a sample of the data I have. I want to match the data in Column A and B. If column B is not matching column A, I want to add a row and copy the data from Column A to B. For example, "4" is missing in column B, so I want to add a space and add "4" to column B so it will match column A. I have a large set of data, so I am trying to find a different way instead of checking for duplicate values in the two columns and manually adding one row at a time. Thanks!

    A B C D

    3 3 Y B
    4 5 G B
    5 6 B G
    6 8 P G
    7 9 Y P
    8 11 G Y
    9 12 B Y
    10
    11
    12
    11
    12

  136. vivek singh says:

    I have a sheet in which I am trying to find out that a particluar cell value will happen on which date. I have a column where there are equal installments of 2 Lakhs and there is column beside it containing dates starts from 01.04.2017 and ends on 01.01.2024 for those installments. Now, if for the first installment customer pays only 50,000 till 01.10.2017 then how can I find using the formula that from which date the overdue is coming and how much?

  137. Donald Trump says:

    If in one column there are name entries with negative and partly failing values associated with them and in another column there are name entries with positive yet yet highly conservative values associated with them, how do I sort the dump the negatives, eliminate the failing and merge into a single positive highly conservative list so that I can quickly get to the golf club?

  138. Ames says:

    Hello,

    Very useful, but I need help comparing two columns. I want it to be able to tell that google inc is the same company as Google ABC, or that Brown university is the same as University, Brown. It would be helfpul if the matches are highlighted. Thanks!

    EX:
    Column 1 Column 2
    google inc. Capital one
    Brown University University, Brown
    Visa Google ABC

  139. Ali says:

    I have two column that,the value to be matched with the another one another`s criteria column. First column contains exact number and second column contains number with description.

    Suggest me further..

  140. Raghul says:

    Product Id Current profit Margin Last yr profit margin
    123 51% 49%
    126 53% 50%
    129 55% 51%
    132 57% 52%
    135 59% 53%

    Mark red color for the cells where last year profit is greater than current year profit and color pink for the product id which is red cells

    have to find using conditional formatting

  141. Prateek says:

    Hi,
    Context - i have 2 versions of a document. In it i have 2 tables with alphanumeric values which i want to compare to see if any changes have been made in the recent version.

    Requirement - i want to compare the alphanumeric values of the two columns (one column from each table as mentioned above) tables and want to highlight only the part that has been changed instead of the whole cell and want the result in a third column.

    Question - is there a resolution to the above scenario?

  142. ecool says:

    thanks, this page information help me a lot

  143. Jeremy says:

    Hello,

    I am wanting to compare two columns of data and if those columns are equal, I'd like to execute a calculation.

    I am using the formula:

    =IF('Raw Data'!A:A=Analysis!A:A,SUMPRODUCT('Raw Data'!C:C,'Raw Data'!I:I)/SUM('Raw Data'!I:I))

    This returns FALSE. How do I fix it?

  144. SREEJITH says:

    wow!!!!!!!!!!!!great...thanks...really useful....

  145. SREEJITH says:

    =IF(COUNTIF($A:$A, $B2 )=0, "REQUIRED", "NOT REQUIRED")

    I want this formula to be stopped when $Bx is null...

  146. cK estrada says:

    I have 2 columns, each column have value. Is it possible to move a value beside its same value? for example:
    Column 1 Column 2 OUTPUT
    1 1 1
    2 3
    3 3

  147. Yvonne says:

    Hi,

    I have 3 columns of data and am comparing Column 3 data with Column 1 and 2 for duplicates. I could use the conditional formatting but I was thinking if there is an excel formula that I could use?

    Column 1 Column 2 Column 3
    15 14 12
    12 17 11
    11 18 14
    10 17 16
    20 25 15

    Thank you.

  148. nader says:

    Hi
    I have tow columns of data. in column2 there is sum of data of column1 how i can compare tow columns and recognize which numbers is sum one number in other column? for example column1 is contains 1,2,5,3,6 and column 2 is 8,9 how i can determine 8 in column2 is sum of which numbers in column 1
    thank you

  149. Gareth A says:

    Hi,

    I need to compare two columns that should be the same, but the data in each comes from different sources.

    Both columns are dd/mm/yyyy hh:mm format.

    My issue is that in one column, there's an extra " " between the date and time, and when I run my comparison =AND formula, the extra space is causing it to fail.

    Can you suggest a way I can easily remove the extra space, or get Excel to ignore the extra space?

  150. Eva says:

    I need a formula that will help me identify duplicate parts/product at different pricing. When I use the conditional formatting on both columns all of the cells are highlighted because it's looking at just the columns as duplicates.

    • Hi, Eva,

      I managed to do that in the following way:
      1) I decided to use a helper column (C) that checks if the product (A1) is duplicated and its price (B1) is unique with the following formula:
      =COUNTIFS(A:A,$A2,B:B,"<>"&B2)
      If the condition is true the formula returns 0, since it can't find any duplicated products with unique prices. Otherwise, it returns 1.

      2) I created a following conditional formatting rule:
      =$C1>=1
      and applied it to my table =$A:$C

      As a result, I can see all the duplicate products with unique prices highlighted in yellow.
      Try to do the same with your data, hope it helps!

  151. Imran Akhtar says:

    I am working on aligning university rankings, as you can see the universities are ranked differently in 2008-2009. Is there a way to use excel to align the universities with corresponding rankings? There are hundreds of them for 12 years, so you can see it is mammoth task.

    2008 2008 2009 2009

    Sussex 26 cardifff 26
    Cardiff 27 Sussex 27
    Queen's 28 Reading 28
    Reading 29 Sussex 29
    Glasgow 30 Surrey 30
    Birming 31 Strathclyde 31
    Manches 32 Manche 32

  152. Fiaz Ahmad says:

    Salaam everyone.
    I have two excel columns each containing 63,000 values. I want to find out all the values where entries of column A are greater than those of column B. How can I do that?
    Thanks in advance
    Stay blessed.

  153. Ashika says:

    Thank you very much. Its working. worth full article!

  154. reza says:

    hi
    i have three unequal column and i want to extract unique cells for first column in compare with two another columns. how can i do it?

  155. zak miah says:

    hi, i need a formula to detect the values of the weight in a column and if it is more than the value then to add 7.50 but if it is less then the value to add 4.
    so for example if the products weigh less than 0.4 then i need the cell to add 4 but if they weigh more than to add 7.5

  156. Brad says:

    Compare to worksheets Sheet2 to Sheet1, find sheet2 match and then return data sheet1 from in 1st cell of this matched column.

    2 work sheets
    1st sheet contains A=data to return (1234) + B-H data to match 456,789,012
    2nd sheet contains criteria to match - look for 456 then return A (1234)

  157. Sunil says:

    Is there a way where we can identify
    1. % similarity
    2. between 2 columns
    3. With strings as data.

    Example:
    Column A | Column B | Match
    Cat is back | Dog is back | 33%
    Superman | Spiderman | 0%

Post a comment



Unfortunately, due to the volume of comments received we cannot guarantee that we will be able to give you a timely response. When posting a question, please be very clear and concise. We thank you for understanding!
Excel add-ins and Outlook tools - Ablebits.com
Ultimate Suite for Excel Professionals
 
 
50+ professional tools for Excel 2016-2007 to do your daily work
Incredible product, even better tech support…AbleBits totally delivers!
Deborah Bryant
Anyone who works with Excel is sure to find their work made easier
Jackie Lee
The best spent money on software I've ever spent!
Patrick Raugh
Ablebits is a fantastic product - easy to use and so efficient.
Debra Celmer
Excel is at its best now
Annie C.
I don't know how to thank you enough for your Excel add-ins
Jennifer Morningstar
Anybody who experiences it, is bound to love it!
Kumar Nepa
AbleBits suite has really helped me when I was in a crunch!
Nelda Fink
I have enjoyed every bit of it and time am using it
Christian Onyekachi Nwosu
It's the best $100 we've ever spent!
Mike Cavanagh
I love the program, and I can't imagine using Excel without it!
Robert Madsen
One word… WOW!
Dave Brown
Love the products!
David Johnston
It is like having an expert at my shoulder helping me…
Linda Shakespeare
Your software really helps make my job easier
Jeannie C.
Thanks for a terrific product that is worth every single cent!
Dianne Young
I love your product
Brad Gibson
Awesome!!!
Sheila Blanchard