Results 1 to 5 of 5
  1. #1
    Mozencrath is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Nov 2012
    Posts
    11

    Related Forms

    Hi All, I am totally stumped on this. My company does military sales, and the military buys its parts based on NSN numbers. An NSN number might have just one part number for it or it might have many different PN's from different manufacturers..I have two tables that are already populated with 10,000 records so I would not be adding any records, simply viewing. I exported the information from a paid service that provides this history... :



    Table 1 "Products" has Fields:
    National Stock Number ("NSN") (An NSN can have mutliple part numbers so each NSN might have multiple records)
    Description
    Weight
    Part Number (A NSN has many different Part Numbers)

    Table 2 "Contracts (Orders)" has fields
    Contract No (A contract can have many NSN numbers therefore could have multiple records)
    NSN
    Total Price
    Company Awarded the Contract

    What I am trying to do is figure out how to do the relationships to allow a database to search by NSN to see all the contracts for that NSN or to search by Contract and see what NSN's are on that contract. For example, in the PRODUCTS table, if the NSN is 123-0987 and it has 3 part numbers, there will be 3 records for that NSN number. Any help or discussion would be greatly appreciated...

    EDIT: I should note that not ALL NSN's have contracts which is why I need the info in two tables...

  2. #2
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    Quote Originally Posted by Mozencrath View Post
    ...figure out how to do the relationships to allow a database to search by NSN...
    Is there any way you can JOIN your two tables? If not, you will have to search two different recordsets for each NSN search request.

  3. #3
    Mozencrath is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Nov 2012
    Posts
    11
    Quote Originally Posted by ItsMe View Post
    Is there any way you can JOIN your two tables? If not, you will have to search two different recordsets for each NSN search request.
    Yes but how would I do that? Is there no way to create a third table like a Parts-Contracts details table?

  4. #4
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    If you build a query object using the Query Design option you can add your two tables. Then drag the field, I suspect NSN, from one table onto the other table to create the JOIN. You can add fields to the grid located towards the bottom of the window. You can view the data your new query retrieves using Datasheet View.

  5. #5
    Mozencrath is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Nov 2012
    Posts
    11
    Quote Originally Posted by ItsMe View Post
    If you build a query object using the Query Design option you can add your two tables. Then drag the field, I suspect NSN, from one table onto the other table to create the JOIN. You can add fields to the grid located towards the bottom of the window. You can view the data your new query retrieves using Datasheet View.
    Im trying to stay away from queries and just figure out the proper relationships so I can use a search form

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

Similar Threads

  1. Replies: 3
    Last Post: 03-22-2014, 04:32 PM
  2. Replies: 7
    Last Post: 06-25-2013, 07:55 PM
  3. Replies: 5
    Last Post: 12-14-2012, 04:21 PM
  4. Replies: 7
    Last Post: 07-02-2012, 10:50 PM
  5. Link two forms to display related data
    By KrisDdb in forum Forms
    Replies: 3
    Last Post: 09-19-2011, 02:41 PM

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