Results 1 to 2 of 2
  1. #1
    justme1234 is offline Novice
    Windows 10 Access 2013 64bit
    Join Date
    Oct 2017
    Posts
    4

    Limiting data shown on the form to enter new data

    Hello,
    I am new to Access and I have a question. I have a database with 2 tables: a table storing computer server information, such as server model number, serial number, etc. and a table storing software information, such as license key, installation date, etc. In the computer server table, I am using the serial number as the primary key and in the software information table I am using the license key as the primary key. The relationship between the computer server and software is 1-to-1, each computer can have only 1 software license and each license can only be installed on one computer.

    So to link the 2 tables together, I created a lookup field in the computer server table and I am able make the relationship unique so that I would get an error if I assign the software key to more than one table.

    Here is my question: when I put in a new entry for a server, I would like to see only unassigned software key in that lookup field. Currently when I click on that field, it shows all available software keys. How can I limit to only unassigned keys?

    Thanks and sorry for the newbie question.

    Denny

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,815
    Combobox RowSource would be a query that joins the two tables on the two software fields. Join type "Show all records from software table ...". Have a WHERE clause - WHERE [software field from computer table] Is Null

    You might also want code in the combobox AfterUpdate event to requery the combobox.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

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

Similar Threads

  1. Replies: 1
    Last Post: 09-01-2017, 10:28 AM
  2. Data entered into form is not shown in Table
    By engr_saud1 in forum Forms
    Replies: 5
    Last Post: 04-07-2013, 06:34 AM
  3. Replies: 1
    Last Post: 07-16-2012, 02:10 PM
  4. Code to sort data shown on a split form
    By meissnerb in forum Programming
    Replies: 1
    Last Post: 05-03-2012, 04:34 PM
  5. Replies: 4
    Last Post: 01-04-2011, 06:30 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