Results 1 to 3 of 3
  1. #1
    Join Date
    Apr 2003

    Unanswered: Searching through records

    I'm trying to do a search by using the Access query(not vba) to serach for all records that is not in a another database but was unsuccessful with it. I have try the vba way but the filter and find method to search for social security number is too slow. if it was a string, it can search for it quickly (I dont know why though, i'm curious about it) Anyways, here is what i'm doing now. The MinUnitData table is the new data and I want to scan the mwpat table to see if the "PatientID" is in the security number table.

    I have try the not and not like, and it didn't work for me
    SELECT MinUnitData.PatientID
    FROM MinUnitData INNER JOIN mwpat ON MinUnitData.PatientID = mwpat.[Social Security Number]
    WHERE ((Not (MinUnitData.PatientID)=[mwpat].[social security number]));

    What else can I do?
    Last edited by lansing; 08-06-03 at 10:34.

  2. #2
    Join Date
    Dec 2002
    Préverenges, Switzerland
    the query wizard has a "find unmatched" option. even if the wizard doesn't directly fit your situation, you can view the SQL to see the syntax.


  3. #3
    Join Date
    Apr 2003
    It took me a while to find the "Find Unmatched" query. You have to click on the NEW button actually.

    Thanks it worked but I dont understand how it works though. I'm seeing there is an relationship arrow pointing to mwpat table? What is it? Also, why is the security number criteria set to Null.

    Here is a screen shot of the query.

Posting Permissions

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