Business Rule Delete detection

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-05-2009 05:29 AM
I have a business rule set up to populate another table after the initial table has had and update/delete/insert done to it. What my issue is that I am not sure how to tell what record has been deleted from the inital table so that I can delete it from the child table. I am open to trying any ideas to acomplish this task. The way I have it set up now is not efficient at all for the size of the table that I will be working with (right now i'm only using test data, like 10 records).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-05-2009 01:54 PM
I don't really understand what you are trying to do but this might help.
http://wiki.service-now.com/index.php?title=Cascade_Delete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-05-2009 04:39 PM
Cascade delete would be my first recommendation. You also have access to the current object in an after business rule on delete actions so you could identify what was deleted and figure out what needs to be cleaned up in the remote tables.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-06-2009 10:58 AM
I got it working on a before delete action through a business rule. Thanks for the help.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-06-2009 11:48 AM
You should be careful deleting remote records in a before rule. If you ever have another rule that runs after the first one and ends up aborting the delete, it will be too late, the remote records would have been deleted already.
An after rule is safer, that way you know the delete actually happened.