Linking Tables and Fields...

K

Kgwill85

I'm having problems with this process. I have multiple tables and I
would like to know if there is a way to have certain fields in
different tables reflect one another. Some of the fields in their
respective tables are the same. Example, Table A and Table B both
have a field named SID.

I want the tables to be able to recognize when the same entry in the
SID field is being deleted or changed. For instance, when Table A
deletes the entry of say..."8888" in the SID field, I want Table B to
delete "8888" in it's SID field as well.

Any suggestions? If you need me to be clearer just let me know.
 
D

Douglas J. Steele

If I'm understanding you correctly, you shouldn't need to do that. Each
piece of data should exist in one place only: you should not have data
replicated in multiple tables.

If SID is the primary key in one table and a foreign key pointing to that
table in another table, you can set up relationships between the two tables
to do cascade updates or cascade deletes.
 
K

Kgwill85

If I'm understanding you correctly, you shouldn't need to do that. Each
piece of data should exist in one place only: you should not have data
replicated in multiple tables.

If SID is the primary key in one table and a foreign key pointing to that
table in another table, you can set up relationships between the two tables
to do cascade updates or cascade deletes.

--
Doug Steele, Microsoft Access MVPhttp://I.Am/DougSteele
(no e-mails, please!)








- Show quoted text -

I get an error when I try to set up the cascade feature for updating
and deleting.

It says... "No unique index found for the reference field of the
primary table"
 
D

Douglas J. Steele

The obvious question is do you have a primary key defined for the table? You
must in order to enforce RI.
 
Top