Establishing relationship necessary with lookup table?

  • Thread starter Thread starter rovelet
  • Start date Start date
R

rovelet

Because of a search on the web, I now know why I have been
encountering problems with queries in the few databases I have made:
due to using the lookup table wizard in tables.

If I understand correctly one should create a combo box, in a form,
that will be used to choose data from a lookup table (or a query based
on the lookup table). The chosen data is then used as input in the
intended field (being a text field instead of a lookup field) of the
table underlying the form.

If this is the case, is it necessary to relate the lookup table to the
table underlying the form and why?
 
Because of a search on the web, I now know why I have been
encountering problems with queries in the few databases I have made:
due to using the lookup table wizard in tables.

If I understand correctly one should create a combo box, in a form,
that will be used to choose data from a lookup table (or a query based
on the lookup table). The chosen data is then used as input in the
intended field (being a text field instead of a lookup field) of the
table underlying the form.

If this is the case, is it necessary to relate the lookup table to the
table underlying the form and why?

Necessary? No. Correct? Yes. Why? Because there is a relationship in the data,
therefore your database should reflect that.
 
If this is the case, is it necessary to relate the lookup table to the
table underlying the form and why?

It's a good idea, because having the relationship ensures that the
data integrity is maintained between the two tables. If you have a
relationship, you'll get an error message if you attempt to delete a
record from the lookup table if doing so would leave "orphans" in the
main table, or if someone bypasses your form and tries to enter an
invalid value into the foreign key field.

John W. Vinson [MVP]
 
It's a good idea, because having the relationship ensures that the
data integrity is maintained between the two tables. If you have a
relationship, you'll get an error message if you attempt to delete a
record from the lookup table if doing so would leave "orphans" in the
main table, or if someone bypasses your form and tries to enter an
invalid value into the foreign key field.

John W. Vinson [MVP]

Thank you so very much for the clarification.
 
Back
Top