Activity Forums Salesforce® Discussions In Which Sequence Trigger and Automation Rules run in Salesforce.com?

  • shariq

    Member
    September 22, 2018 at 10:42 pm

    The following is the order Salesforce logic is applied to a record.

    Old record loaded from database (or initialized for new inserts)
    New record values overwrite old values
    System Validation Rules
    All Apex “before” triggers
    Custom Validation Rules
    Record saved to database (but not committed)
    Record reloaded from database
    All Apex “after” triggers
    Assignment rules
    Auto-response rules
    Workflow rules
    Escalation rules
    Parent Rollup Summary Formula value updated (if present)
    Database commit
    Post-commit logic (sending email)
    Additional notes: There is no way to control the order of execution within each group above.

  • Parul

    Member
    September 23, 2018 at 3:33 am

    Adding some points:

    Assignment rules run when:

    An API client inserts a Lead and specifies an AssignmentRuleHeader. This is typical for Marketing Automation Systems like HubSpot or Marketo.
    A DML statement is executed that includes DmlOptions with property AssignmentRuleHeader set.
    The user clicks ‘assign using active assignment rules’ on the OOTB Lead edit page.
    These three rules tell SFDC to execute assignment rules. Just doing a DML insert without any AssignmentRuleHeader set explicitly or implicitly does not run the assignment rules.

     

    Thanks

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos