Related Record is Required in Table Error

  • Thread starter Thread starter Droogie
  • Start date Start date
D

Droogie

Hello,

Why do I keep getting the folowing error when I try to enter data both from
an access form and via my ColdFustion App?: You cannot add or change a
record because a related record is required in table...

I don't get the error when relationships are defined but once they are, the
error appears.

Thanks in advance,
Droogie
 
I think you meant you don't get the error if relationships are not defined.

This is normal behaviour for a relational database. It appears the table
you are describing is a child table to another table. It needs a value in
the field used to relate the record that matches a record in the parent table.
 
Klatuu (Jabba's Skiff Guard?),

Gotcha! Now, perhaps this is beyond the scope of this forum but if I'm
submitting data to this table from a ColdFusion form and the select field is
not chosen and I've assigned it a value of "-1", how to I force the table to
accept this so the form will process? For example, one of my select fields
is "Titles" (Dr., Mr., etc.). It is not a required field but when I try to
submit the form (and even when trying to add data in access in table view or
form view, it will not accept a value not equal to the foreign key it is
referencing.
 
I don't know ColdFusion, but in Access, you would need to select a record in
the parent table, get the value of the linking field, and put it where it
would be updated with the rest of the record.
 
Back
Top