Results 1 to 2 of 2
  1. #1
    whitelockben is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Oct 2011
    Posts
    5

    Find records with matching field value & compare records showing non-matching

    Hi all,



    I have two table with matching structures and I want to compare records between the two tables where field 1 is identical. However on one table some of the records appear more that once.

    eg:

    TBL1
    Field 1 Field 2 Field 3
    A _____x_____ x
    C _____x_____ x
    D _____x_____ y

    TBL2
    Field 1 Field 2 Field 3
    A_____ x_____ x
    C _____x_____ x
    D _____x_____ y

    I want records that dont match to then be shown.

    Ie
    Field 1 Field 2 Field 3 Field 4 (difference)
    D _______x______y______ x

    Is this possible?

  2. #2
    Stingaway is offline Efficiency Junkie
    Windows 7 64bit Access 2010 64bit
    Join Date
    Sep 2011
    Location
    The deep south. Keep going until you hit water basically.
    Posts
    224
    Basics: put the two fields together in a query with a left join on the field 1, adding each field that you want to compare from both tables. In the query, put a condition on the second table field column you are trying to compare - 'not like table1.fieldname' or similar.

    If by difference (field 4) you mean a number, just put another column in your query that is =[field2]- [field3] and call it field4...

    Hope that helps. It's tricky to try to visualize what you are seeing...

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

Similar Threads

  1. Replies: 1
    Last Post: 08-11-2011, 11:33 AM
  2. Replies: 6
    Last Post: 02-10-2011, 07:09 AM
  3. Concatenating fields from matching records
    By MWMike in forum Queries
    Replies: 1
    Last Post: 10-28-2010, 10:49 PM
  4. Replies: 9
    Last Post: 06-23-2010, 02:06 PM
  5. Join queries that do not have matching field
    By Petefured in forum Queries
    Replies: 2
    Last Post: 05-04-2010, 11:19 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