Results 1 to 5 of 5
  1. #1
    stosh59 is offline Novice
    Windows XP Access 2003
    Join Date
    Jan 2011
    Posts
    8

    Table Join on Text

    I have two tables where the only unique item between the two may be first name and last name. I say "may be" because the tables are from two different sources, and I am trying to find where names from Table A match to names in Table B.



    The key to both tables is random sequence assigned by Access.

    Table A has 32,678 rows
    Key (1,2,3,4,5....)
    Last Name
    First Name
    And lots of other stuff.

    Table B has 456 rows
    Key (1,2,3,4,5...)
    Last Name
    First Name

    I can't just join on Last Name for obvious reasons. I have tried all combination of joins with varying results; none of which are useful. This should be easy, shouldn't it?

    Thank you for your guidance in advance!

  2. #2
    Tigger is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2011
    Posts
    6
    Connecting on text fields can always be tricky depending on the cleanliness of the source information. But if you are looking to connect on first and last name, use both of those fields as joins.

    If you are building a query, they you can look to show all records from one table on only those matching from a second (left/right joins).

  3. #3
    stosh59 is offline Novice
    Windows XP Access 2003
    Join Date
    Jan 2011
    Posts
    8
    Thank youTigger. So I tried a left join:
    SELECT PrevEv.[Last Name], PrevEv.[First Name], CFList.[Last Name], CFList.[First Name]
    FROM PrevEv LEFT JOIN CFList ON (PrevEv.[First Name] = CFList.[First Name]) AND (PrevEv.[Last Name] = CFList.[Last Name]);

    And I got a list of all the names in the PrevEv list, but none from the CFList.

    I have manually browsed both tables and I know there are matches. Any other ideas?

    Thanks!

  4. #4
    Tigger is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2011
    Posts
    6
    stosh - if you are not getting any matches, then it may actually be data related. are there space characters in one source and not the other? You may need to do some scrubbing before trying to match.

  5. #5
    stosh59 is offline Novice
    Windows XP Access 2003
    Join Date
    Jan 2011
    Posts
    8
    I think you are right. Thanks for the ideas!

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Join Key of table in recordset
    By Rohit0012 in forum Forms
    Replies: 14
    Last Post: 09-24-2011, 09:04 PM
  2. join table
    By graciemora in forum Queries
    Replies: 2
    Last Post: 10-28-2010, 01:57 PM
  3. Join A Recordset to the current db Table
    By mjellis in forum Programming
    Replies: 0
    Last Post: 08-10-2010, 02:44 PM
  4. Error on Multiple Table Join & IIF
    By cmartin in forum Queries
    Replies: 1
    Last Post: 05-21-2010, 08:58 PM
  5. Self Join in a Table
    By LornaM in forum Database Design
    Replies: 10
    Last Post: 05-06-2009, 10:29 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums