+ Reply to Thread
Results 1 to 8 of 8

Help please: Compare two columns in one sheet with two columns in another sheet

  1. #1
    Registered User
    Join Date
    11-09-2011
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    8

    Question Help please: Compare two columns in one sheet with two columns in another sheet

    Hi guys,

    Hoping someone can help with this.

    I have two columns (A and B) in a sheet and two columns (A and B) in another sheet.

    I want to check that the combination of column A and B in Sheet 1 matches the combination of column A and B in Sheet 2.
    If they match then I want a 'Match' (or something to that effect) in column C of Sheet 1 otherwise 'No Match'.

    Hope someone can help me soon!

    Thanks!

    P.S. Sorry if this has been answered before, I couldn't quite find it!

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,022

    Re: Help please: Compare two columns in one sheet with two columns in another sheet

    Will you please attach a SMALL sample Excel workbook (10-20 rows of data is usually enough)? Please don't attach a picture of one (no-one will want to re-type all your stuff before starting).

    1. Make sure that your sample data are truly REPRESENTATIVE of your real data. The use of unrepresentative data is very frustrating and can lead to long delays in reaching a solution.

    2. Make sure that your desired solution is also shown (mock up the results manually).

    3. Make sure that all confidential information is removed first!!

    4. Try to avoid using merged cells. They cause lots of problems!

    Unfortunately the attachment icon doesn't work at the moment. So, to attach an Excel file you have to do the following: Just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  3. #3
    Registered User
    Join Date
    11-09-2011
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Help please: Compare two columns in one sheet with two columns in another sheet

    File attached (I hope!)

    So in column C of Sheet 1 you can see the desired result.

    Thanks!
    Attached Files Attached Files

  4. #4
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Help please: Compare two columns in one sheet with two columns in another sheet

    Enter in C2 on Sheet1 and copy down
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    v A B C
    1 CC Code CC Number
    2 AA 112233 Match
    3 AB 222222 No Match
    4 AC 454545 Match
    5 BB 556689 Match
    6 CC 784466 Match
    7 CD 778855 Match
    8 ED 554433 No Match
    9 AA 112244 No Match
    10 CC 223311 Match
    11 BB 222222 No Match
    If you like my answer please click on * Add Reputation
    Don't forget to mark threads as "Solved" if your problem has been resolved

    "Nothing is so firmly believed as what we least know."
    --Michel de Montaigne

  5. #5
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,022

    Re: Help please: Compare two columns in one sheet with two columns in another sheet

    It's attached!

    Shhet1, c2, copied down:
    =IF(ISNUMBER(MATCH(1,INDEX((Sheet2!A2:A11=Sheet1!A2)*(Sheet2!B2:B11=Sheet1!B2),0),0)),"Match","No Match")
    Attached Files Attached Files

  6. #6
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Help please: Compare two columns in one sheet with two columns in another sheet

    Also can be done with COUNTIFS function
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Last edited by AlKey; 09-04-2017 at 01:18 PM.

  7. #7
    Registered User
    Join Date
    11-09-2011
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Help please: Compare two columns in one sheet with two columns in another sheet

    Thank you very much guys, all work well.

  8. #8
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,022

    Re: Help please: Compare two columns in one sheet with two columns in another sheet

    You're welcome and thanks for the rep.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 2
    Last Post: 07-21-2017, 11:46 AM
  2. Replies: 3
    Last Post: 12-15-2015, 05:04 PM
  3. Macro to Compare two columns and publish sheet name in case columns dont match
    By adaws in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-06-2014, 01:21 PM
  4. Replies: 1
    Last Post: 10-04-2012, 02:31 PM
  5. Replies: 4
    Last Post: 06-14-2012, 11:23 AM
  6. Replies: 4
    Last Post: 04-05-2012, 11:30 AM
  7. Replies: 5
    Last Post: 09-24-2009, 03:46 AM

Tags for this Thread

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