You need to sign in to do that
Don't have an account?
ChristineVW
What (if anything) Is Wrong With This Scenario - Two Triggers for Two Custom Objects
I have two custom objects, Development Requests and Jobs. I need changes on a Job record to trigger changes to a picklist field on a related Development Request. In turn, a limited number of field changes on a Development Request record should trigger changes to a picklist field on a related Case.
Since Cases are chained to Development Requests, and Development Requests are chained to Jobs - through two separate lookup relationships - can I just create two "before update" triggers, one on the Job object, and one on the Development Request object? Is there anything wrong with that? It seems weird to have a field change caused by a trigger to instigate the firing of another "before update" trigger.
Since Cases are chained to Development Requests, and Development Requests are chained to Jobs - through two separate lookup relationships - can I just create two "before update" triggers, one on the Job object, and one on the Development Request object? Is there anything wrong with that? It seems weird to have a field change caused by a trigger to instigate the firing of another "before update" trigger.
werewolf
Nope. Nothing wrong with that at all.
werewolf
...as long as your triggers don't trigger each other recursively. But it sounds like you'll just be chaining one custom object to another custom object to Case, so that's fine.
Box
If there is a recursive trigger issue you can just build a class containing static objects to store what IDs have already been processed by this trigger and use this as a process control.