deleting all related sub records when deleting the "main" record. (1 Viewer)

Roy riggsjø

Registered User.
Local time
Today, 01:29
Joined
Apr 11, 2008
Messages
11
I have two tables.

1. Persons (list of persons)
2. Job history (list of jobs)

each person have their own job history. all these jobs are stored in the job history table. when i delete a person i would like the job history for this person deleted as well. each job stored in the job table have a field with person name, so that it is linked to this person.

how can i do this? vba or simple properties options?

- Roy
 

Oldsoftboss

AWF VIP
Local time
Today, 11:29
Joined
Oct 28, 2001
Messages
2,504
If you have created a relationship between the 2 tables, you should enforce referential integrity and check the "Cascade delete related records" check box
 

Users who are viewing this thread

Top Bottom