The "Category_PK" field in tblCategories is an AUTONUMBER type. Access enters/creates number this automatically whenever a new record is created.
The "Category_FK" field in tblProducts is an LONG INTEGER type. It is just a field that stores numbers (instead of text or dates). It is manually entered. (Well, the exception is if you set a default value)
Wait, Steve in the tblProducts, in the Category_PK fld did you manually typed in the numbers?
YES,YES, I manually entered the numbers into the "Category_FK" field in tblProducts. It is just another field.
Why wouldn't the Category_PK (auto numbers) populate in the tblProducts
Because the "Category_PK" field (you created/named) CANNOT be an autonumber type field in tblProducts. There can be only ONE autonumber field in a table. And that field is the ProductID_PK field (in tblProducts).
In "tblProducts" change the name of the field "Category_PK" to "BANANAS" (you will have to update the queries
). As long as the field type is still a Long Integer, you can still create a relationship with tblCategories "Category_PK" field as a one-to-many.
Code:
tblCategories (the one) tblProducts (the many)
Category_PK (autonumber) -> Category_FK (LONG INTEGER)
In the "cCC_Box" mdb, on the main form, there is an "ADD" button. It opens a form to add new categories and/or products. In the top part, select Beverage. In the sub-form enter "Orange" and "Root Beer" Add a new record to the categories "Meat". In the subform enter "Beef", "Fish" & "Chicken".
Close the "Add" form and open the main form. In the category combo box, select Meat, then look at the combo box Products.