• Significance of any record in query results

    Home » Forums » AskWoody support » Productivity software by function » MS Access and database help » Significance of any record in query results

    Author
    Topic
    #487048

    I have 3 tables: Sales, items, customers. Each has an autonumber key field. The Sales table includes a foreign field for items and for customers. The links work correctly.
    To find any sales records without matching records in the items table, I ran the unmatched query wizard and got a query named “Sales without matching items” which has what looks like an empty or new record, signifying there are no sales without valid items. Then I ran the unmatched query wizard to find out if I had Sales without matching customers. “Sales without matching customers” has no empty record – it is gray below the field names and navigation buttons are “grayed out”.
    What is the significance of the difference?

    Thanks.
    Sanora

    Viewing 1 reply thread
    Author
    Replies
    • #1365490

      Sanora,

      I may be wrong but it seems to me that the Sales table should not have a foreign key for items but rather the Items table should have a foreign key for Sales {using the AutoNumber value from the sale}. As each customer can have multiple sales and each sale can have multiple items. Of course, not having your table structure makes this somewhat of a guessing game. It would help if you posted the table structures. :cheers:

      May the Forces of good computing be with you!

      RG

      PowerShell & VBA Rule!
      Computer Specs

    • #1365518

      I tried to pose the question without the back-story, but here’s a quick summary. The original database was badly designed – really not designed, just built. We are trying to rebuild the system, and have a lot of faulty data to salvage. As part of the cleanup, we were hunting incomplete records – hence the ‘all sales without matching customers’. Access was doing what we needed, but we were concerned by the difference in responses and figured there was a reason why.

      In this case, we were indeed hunting any sales records that did not have customers.

      Thanks, and I should have given more info.
      Sanora

    Viewing 1 reply thread
    Reply To: Significance of any record in query results

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: