+ Reply to Thread
Results 1 to 5 of 5

Comparing Columns

Hybrid View

  1. #1
    Registered User
    Join Date
    10-26-2010
    Location
    Sacramento California
    MS-Off Ver
    Excel 2003
    Posts
    8

    Comparing Columns

    Hi, i need a formula that would compare the first 8 characters of one column to the second 8 characters of the next column, and if they didn't match wit would give me an error.
    for example:
    column a has 02908956_1944-05-23_1Electric Log and column b 02908956.tif it would be good.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Comparing Columns

    Are you matching entries in single rows?

    e.g

    =LEFT(A2,8)=B2

    this compare A2 to B2 and returns TRUE if matched.

    If you want to search column B for a Match

    =Isnumber(match(Left(A2,8),B:B,0))

    copied down.
    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
    10-26-2010
    Location
    Sacramento California
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: Comparing Columns

    Not sure, I use it to rename files, but i want to make sure that the first 8 characters match in each column.one is the original file name, one is the name it is going to be after the rename

  4. #4
    Registered User
    Join Date
    03-18-2004
    Location
    Sheffield
    MS-Off Ver
    Excel, Access, 2007
    Posts
    42

    Re: Comparing Columns

    try (in space c1 for example)
    =IF(LEFT(A1,8)=LEFT(B1,8),"match","mismatch")

    oops - see another reply while I was in process - sorry
    Last edited by JulieM; 10-26-2010 at 01:22 PM. Reason: another reply, not seen while typing
    I count on Excel for everything

  5. #5
    Registered User
    Join Date
    10-26-2010
    Location
    Sacramento California
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: Comparing Columns

    You are Awesome!!!!!!

+ 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