Results 1 to 3 of 3

Thread: Discrepancies

  1. #1
    Star Lounger
    Join Date
    Jun 2009
    Posts
    59
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Discrepancies

    I manage three tables in my Access database:
    1. The first is a linked table (Board) from our internal SharePoint site.
    2. The second is a linked table (Contacts) from our internal SharePoint site.
    3. The third is a linked table (Board of Directors) from an external SharePoint site.


    I have a query that joins the Board and Contacts tables from our internal SharePoint(because we sometimes have the same contact sit on multiple boards, thus the need to only manage one contact). The query name is "query_board", which basically represents the system of record. The external table (Board of Directors) is updated when changes are made. The below SELECT query is working perfectly to identify new records, which i then perform an append query.

    SELECT query_board.Association, query_board.[Association Number], query_board.Office, query_board.Prefix, query_board.[Full Name], query_board.Email, query_board.[Home Phone], query_board.[Mobile Phone], query_board.[Business Phone], query_board.[Date On], query_board.[Date Off], query_board.ID
    FROM query_board LEFT JOIN [Board of Directors] ON query_board.ID = [Board of Directors].SharePointID
    WHERE ((([Board of Directors].SharePointID) Is Null));

    Unfortunately, I can't get figure out how to identify discrepancies between the query results and the external table:

    SELECT query_board.[Home Phone], query_board.[Mobile Phone], query_board.[Business Phone]
    FROM [Board of Directors] INNER JOIN query_board ON [Board of Directors].SharePointID = query_board.ID
    WHERE (((query_board.[Home Phone])<>[Board of Directors].[HomePhone])) OR (((query_board.[Mobile Phone])<>[Board of Directors].[MobilePhone])) OR (((query_board.[Business Phone])<>[Board of Directors].[BusinessPhone]));

    For simplicity, I'm only comparing three fields, normally it would be all. I know for a fact I have records with different phone numbers, but the results is always zero records returned. Any ideas? I'm banging my head against a wall. Thanks in advance!

  2. #2
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts
    I'd first run that Select query without the WHERE clause, perhaps adding the Phones from the [Board of Directors] table to it to make sure anything is selected at all.
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

  3. #3
    Star Lounger
    Join Date
    Jun 2009
    Posts
    59
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi Mark,

    Thanks for the response. I gave that a shot and sure enough both phone number columns were returned, one with a phone number and the other empty...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •