Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error message when choosing from a combo-box. It's got me stupmed

Status
Not open for further replies.

vistor

Technical User
Dec 22, 2000
164
US
I have a combo box that looks up a contact from the contact table and then fills in the contacts name, address, etc. on the form. Pretty standard.

The primary key on the Contact table is ID, an auto number.
The foreign key on the Meeting table is ID, a number
Relationship is From the Contact table to the Meeting table

This is the error message you get when you try to choose a contact from the combo box on the form:
The Current field must match the join key ‘?’ in the table that serves as the ‘one’ side of one-to-many relationship. Enter a record in the ‘one’ side table with the desired key value, and then make the entry with the desired join key in the Many-only’table

I've redone both the relationship and the combo box several times, but keep getting the error message. Any ideas?
 
vistor:

Please see my response in the following thread:

thread181-484744


HTH,

Vic
 
No, this is not the answer. There is a the contact and meeting tables do have a relationship
 
vistor:

Try removing the relationship between the contact table and the meeting table as well. You are only using the contact table for the purposes of data normalization. Basically as just a lookup table. It's use is so you don't have to store the same repetitive text data in your maintable. Thats the first step in data normalization.

Does the data in the Contact table change if data in the meeting table changes? I would suspect not. But if you change the spelling of a contact in the Contact table, then every instance in the Meeting table referencing that Contact will change accordingly. This is the function of a lookup table, not a relationship table.

By making any of your lookup tables directly relate to any other table in the relationships window, it will prevent you from making changes to your maintable recordset, since more than one record in your maintable uses the Contact primary key as its foreign key.

If, when you look at your mainable in table view, you want to see the contact name instead of a number, just go to table design mode and on the Lookup tab for the contact field, change the Display Control to a listbox or textbox. Then you can set the Row Source equal to your Contact table. You can then tell it which column in the Contacts table is the bound column and how many columns you want to show in the list, as well as the columns' widths.

HTH,

VIc
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top