+ Reply to Thread
Results 1 to 7 of 7

Help using a formula to compare two colums of text.

  1. #1
    Registered User
    Join Date
    08-19-2014
    Location
    Bridgend
    MS-Off Ver
    2010
    Posts
    21

    Help using a formula to compare two colums of text.

    Hello Forum,

    I am trying to compare two columns with location data drawn from two different sources, thusly returned with two different methods of reporting.

    Specifically (this data is made up as an example):

    Client has two sites. Cardiff as the head office and London as the field office.

    Client database lists these two as Cardiff and London.

    Discovery tool lists these as HQ and Field respectively.

    I am trying to find a function that would allow me to compare the two and match Cardiff to HQ, and London to Field. Reporting it in the manner displayed in the example below:


    Sample Data 2.jpg
    Attached Images Attached Images
    Last edited by Fizban; 01-06-2015 at 10:20 AM. Reason: Fixing Image Link

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Help using a formula to compare two colums of text.

    Would you upload the workbook that contains the two lists so that we can see the request in context.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Valued Forum Contributor PeteABC123's Avatar
    Join Date
    09-21-2012
    Location
    Chicago, IL
    MS-Off Ver
    MS Office 365 ver 2202
    Posts
    1,104

    Re: Help using a formula to compare two colums of text.

    I'd create a helper column consisting of creating a combined value of your row fields.
    For example:
    In D2 enter
    =A2&B2 and copy down.
    In C2, enter and copy down:
    =IF(COUNTIF(D:D,D2)>1,"TRUE","FALSE")

    If this helps you, please let us know.

    Pete

  4. #4
    Registered User
    Join Date
    08-19-2014
    Location
    Bridgend
    MS-Off Ver
    2010
    Posts
    21

    Re: Help using a formula to compare two colums of text.

    Ok, I'll try that when I get into work. I can imagine it working, not sure why I didn't just do that in the first place :P

    I cannot upload the worksheet as it contains sensitive data. Sorry.

  5. #5
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Help using a formula to compare two colums of text.

    Maybe something like this...

    =OR(AND(A2="Cardiff",B2="HQ"),AND(A2="London",B2="Field"))

    Copy down
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  6. #6
    Registered User
    Join Date
    08-19-2014
    Location
    Bridgend
    MS-Off Ver
    2010
    Posts
    21

    Re: Help using a formula to compare two colums of text.

    Thanks Tony!

    Your formula worked perfectly.

    Question Resolved.

  7. #7
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Help using a formula to compare two colums of text.

    You're welcome. Thanks for the feedback!


    If your question has been solved please mark the thread as being solved.

    In the menu bar above the very first post select Thread Tools, then select Mark this thread as solved.

+ 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. [SOLVED] Compare Colums and Color enire row if values (text) do not match
    By GatorsBucs in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-27-2013, 11:43 AM
  2. need formula to compare 2 colums and keep a a value that is lower
    By mtanislav in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-14-2011, 10:56 AM
  3. Split one cell into two by formula not text to colums function
    By robfink2.0 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-27-2010, 02:28 AM
  4. Formula to compare 2 colums looking for exact matches
    By Raisedwell in forum Excel General
    Replies: 7
    Last Post: 08-25-2010, 04:57 PM
  5. Formula to compare colums in different spreadsheets
    By MikeWinn in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-12-2010, 04:43 PM

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