Results 1 to 2 of 2

Thread: Cascade Delete.

  1. #1
    Join Date
    Mar 2002

    Smile Unanswered: Cascade Delete.

    I have a question.Can we not check the Cascade Delte check box if the tables are from more than one databases in the relationship screen in the front end.Let me explain it in more detail.
    I have a front end which has linked tables from three different databases(back ends)I have relationships between these tables in the front end.I would like to Cascade Deletes in some of the relationships.When I right click on a relationship,the cascade delete check box is disabled(I am guessing it is because the tables are linked tables from multiple back ends).Is there any way I can do this?Any comments will be appreciated.The thing I am actually trying to do is allowing the client to delete a record from the primary table from the front end.I would like to enforce Cascade deletes so that all the related records to that record(the user deletes)can also be deleted.I can do this explicitly through code,but I was wonderng if there is an easy way out like Cascade delete.
    Thank you

  2. #2
    Join Date
    Apr 2002
    Access does not feature referential integrety over multiple database (files) . If your users won't edit the table directly you can just write your own cascading delete as in:

    DELETE master_table.*, related_table.*
    FROM master_table
    INNER JOIN related_table ON master_table.SomeID = related_table.SomeID
    WHERE SomeID = [SomeID from current record];

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts