You need to sign in to do that
Don't have an account?
vinni shree
Triggers concept
A developer needs to update an unrelated object when a record gets saved. Which two trigger types should the developer create? (Choose two.)
A. after insert
B. before update
C. before insert
D. after update
Can someone please explain me the correct answer for this.
Thank you
The Correct answer for this is B and C .
Before Update and Before Insert.
Before triggers: used to update or validate record values before they’re saved to the database.
We cannot use After trigger if we want to update a record because it causes read only error. This is because after inserting or updating, we cannot update a record.
Please check the below link for an understanding of Triggers ->
https://developer.salesforce.com/forums/?id=906F0000000AafFIAS (http://www.sfdc99.com/2014/01/25/use-vs-triggers/)
http://www.sfdc99.com/2014/01/25/use-vs-triggers/
Please check the Trailhead module on the trigger so that you can accelerate on trigger concepts one of the best ways to learn the Salesforce.Please check the link below.
https://trailhead.salesforce.com/modules/apex_triggers/units/apex_triggers_intro
I hope it will be helpful.
Please mark it as best answer if it resolved the issue.