
Originally Posted by
June7
The version of your db I have has fESID_ID field in tblAutoModels. It is a number type. This means would save the fESID value from tblEngineSizes as the foreign key.
If you want to save fEngineCode as foreign key in tblAutoModels then field fESID_ID has no purpose in tblAutoModels.
I understood purpose of this form/subform is to create new records in tblAutoModels by applying filter to main form to select manufacturer then creating related records in the subform. Probably want to select an engine size in combobox on subform and display related info somehow. The only info in tblEngineSizes is the code and size. Instead of the form RecordSource query to retrieve the related info, could just show it in combobox. Maybe that will simplify this issue for you. I probably should have suggested that approach to begin with.
Again, need to be sure which field in tblEngineSizes will be the PK/FK.
Suggestions for combobox RowSource depending on the PK/FK:
SELECT fESID, fEngineCode & " : " & fEngineSize As EngSize FROM tblEngineSizes;
SELECT fEngineCode, fEngineCode & " : " & fEngineSize As EngSize FROM tblEngineSizes;
In both cases, other properties of combobox:
BoundColumn: 1
ColumnCount: 2
ColumnWidths: 0", 1.5"