Activity Forums Salesforce® Discussions What is the difference between Recursive Trigger and Circular Trigger in Salesforce?

  • Anurag

    Member
    August 17, 2018 at 2:37 pm

    Hi Madhulika,

    If a trigger is callled again and again than it is called recursive trigger.

    For Eg:
    trigger on Contact (before update){
    update anyContactList;
    }

    In the above example we are updating contact list in before update trigger so it will again call the trigger and our trigger will be called recursively till we stop or block it with the help of a static variable.Circular and recursive triggers are basically same.

  • shariq

    Member
    September 17, 2018 at 11:03 pm

    Hi,

    To add into above -

    1) Many Developers face recursive trigger , or recursive update trigger. For example in 'after update' trigger, Developer is performing update operation and this lead to recursive call.

    2) You want to write a trigger that creates a new record ; however, that record may then cause another trigger to fire, which in turn causes another to fire, and so on.

    Hope this helps.

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos