+ Reply to Thread
Results 1 to 19 of 19

Need help finding duplicates between 2 rows.

  1. #1
    Registered User
    Join Date
    06-25-2008
    Posts
    6

    Need help finding duplicates between 2 rows.

    Just wondering if anyone has a macro, or formula that would allow me to find out (and possibly highlight), when any value in column A is equal to any value in column B. Im dealing with about 2000 rows so its almost impossible to complete manually.

    Sorry the heading is supposed to read need help finding duplicates between 2 COLUMNS

    Regards,

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    Do the matches have to be adjacent to each other... or occur anywhere in the columns?
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    06-25-2008
    Posts
    6
    unfortunately, they occur in any order

  4. #4
    Registered User
    Join Date
    06-25-2008
    Posts
    6
    is there some add-in program that I can buy to complete the task.

  5. #5

  6. #6
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    Quote Originally Posted by sam121
    unfortunately, they occur in any order
    you can use formulas to find matches....

    Say you have column A and possible Matches in Column B...

    in Column C, starting at top, C1, enter formula

    =isnumber(match(A1,B:B,0))

    this will return TRUE if item in A1 exists anywhere in Column B.

  7. #7
    Registered User
    Join Date
    04-01-2008
    Location
    Houston
    MS-Off Ver
    Office 365
    Posts
    85

    You Can Also Use Conditional Formatting

    Hi sam121,

    You could also use this formula in the conditional formatting so it will highlight your cell in column A

    =COUNTIF($B$2:$B$2000,$A2)>=1 edit to formula missed the "equal" sign

    B2:B2000 is your range for the second column with the dups
    A2 is first column, first cell

    Copy and paste special formats....

    Hope this helps also...

    Cullen
    Last edited by Cullen8; 06-25-2008 at 04:34 PM.

  8. #8
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    If you want to highlight items in A that are also in B,

    Then select Column A and go to Format|Conditional Formatting and choose Formula is from 1st drop down menu.

    Enter formula: =Match(A1,B:B,0)

    click Format and choose your colour preference.

  9. #9
    Registered User
    Join Date
    10-17-2007
    Posts
    44
    Now a formula would detect and display how many duplicated cells their are, but myself I uses the FIND and enter the name (or what ever you are going by) and by pressing enter will move the selection to each cells that match. I have employees that enter duplicated persons in my database that are in the same row and not column which I think you are looking for. Once i type the first three to four letter and if the autofill shows, then that tells me that one of my employees has already enter the information. possibly by the time i get to the 3rd or 4th cell and if it autofills, then I know that I don't need to proceed anymore.

  10. #10
    Registered User
    Join Date
    03-05-2008
    Posts
    6
    try conditional formatting? turn cell red if equal to another on the same sheet. or add a "Change"/"OK" column then filter for "Change"

  11. #11
    Registered User
    Join Date
    06-25-2008
    Posts
    6
    is there a way instead of searching for just A1, a whole range of the A column. Thanks for the help so far.

  12. #12
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    Select all of column A and apply suggestion I made in Post #8 above for Conditionally formatting...

    The entire range (column A) will have the format applied to it.

  13. #13
    Registered User
    Join Date
    06-25-2008
    Posts
    6
    seems to work, thanks for the help

  14. #14
    Registered User
    Join Date
    10-17-2007
    Posts
    44
    Can someone else what is Conditionally Formatting and what the purpose of it? I'm kinda new to excel, but I know enough to get by. I probly only know about 50% of all what excel can do, and I want to know more. So what try to be a Master. I've taken a day course for about only 3 days, but I know excel can do alot more then what i've been trained for, cause I seen other documents in the pass and I wonder how they were able to do that.

  15. #15
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    Quote Originally Posted by tinkertron
    Can someone else what is Conditionally Formatting and what the purpose of it? I'm kinda new to excel, but I know enough to get by. I probly only know about 50% of all what excel can do, and I want to know more. So what try to be a Master. I've taken a day course for about only 3 days, but I know excel can do alot more then what i've been trained for, cause I seen other documents in the pass and I wonder how they were able to do that.
    Here's a good explanation of CF.

    http://www.cpearson.com/excel/cformatting.htm

  16. #16
    Forum Contributor EdMac's Avatar
    Join Date
    01-23-2006
    Location
    Exeter, UK
    MS-Off Ver
    2003
    Posts
    1,264
    Hi tinkerton,

    If you're up to 50% you're doing well! I wouldn't rate myself above 20%.

    Conditional formatting allows you to format a cell depending on what it contains or what another cell contains.

    In 2003 you can have up to 3 conditional formats + the default format of the cell.

    On the bar > format > conditional formatting

    check out this site

    http://www.contextures.com/xlCondFormat01.html

    regards
    Ed
    _____________________________
    Always learning, but never enough!
    _____________________________

  17. #17
    Registered User
    Join Date
    10-17-2007
    Posts
    44
    Thanks. I also found a site that has acouple of videos you can watch, so you can get first hand knowledge.

    http://www.contextures.com/xlCondFormat01.html

  18. #18
    Registered User
    Join Date
    10-17-2007
    Posts
    44

    Re: Need help finding duplicates between 2 rows.

    This is an update question someone had mention conditional formatting and it work great when I was using and sometimes still uses version 2003. Where is conditional formatting in the Microsoft Excel 2007 version?

  19. #19
    Registered User
    Join Date
    10-17-2007
    Posts
    44

    Re: Need help finding duplicates between 2 rows.

    Found it. SOLVED!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1