User Tools

Site Tools


salesforce_custom_triggers

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
salesforce_custom_triggers [2018/07/12 23:47]
vinhn
salesforce_custom_triggers [2018/07/12 23:48] (current)
vinhn
Line 11: Line 11:
 Below is a optimized sample script of a custom trigger that avoids multiple SOQL queries and avoids the governor limit of 100 set by Salesforce. Instead of querying for both the Case Ids and CaseComment ParentIds, this script iterates through CaseComment and stores their ParentIds in an array then compares it to the Case Ids for updates through a query. Below is a optimized sample script of a custom trigger that avoids multiple SOQL queries and avoids the governor limit of 100 set by Salesforce. Instead of querying for both the Case Ids and CaseComment ParentIds, this script iterates through CaseComment and stores their ParentIds in an array then compares it to the Case Ids for updates through a query.
  
-<info>Note: There are many ways to write a custom trigger. Refer to this page for guidance or contact [[support@perspectium.com]] for assistance</​info>+<wrap>Note: There are many ways to write a custom trigger. Refer to this page for guidance or contact [[support@perspectium.com]] for assistance</​wrap>
  
 <​code>​ <​code>​
salesforce_custom_triggers.txt ยท Last modified: 2018/07/12 23:48 by vinhn