What will automatically obey the organization-wide defaults and sharing settings for the user who executes the code in the salesforce organization? A. Apex Triggers B. HTTP Callouts C. Apex Controllers D. Anonymous Blocks
The answer is Anonymous Blocks. With the choices that are available, it can be confusing if this is the option or Apex Trigger. Apex Trigger can be used in order to compile data and execute everything that is needed. Apex Trigger can be used in system mode but it is only Anonymous Blocks that can help get user permissions.
Remember that you cannot use Apex Triggers if you want to update a field if you would not be able to use it. You cannot use the other codes that are given to you. The Apex code can get stuck in the metadata but it can be executed when needed.
Hope this helps.
Kindly mark this as solved if the reply was helpful.
The answer is Anonymous Blocks. With the choices that are available, it can be confusing if this is the option or Apex Trigger. Apex Trigger can be used in order to compile data and execute everything that is needed. Apex Trigger can be used in system mode but it is only Anonymous Blocks that can help get user permissions.
Remember that you cannot use Apex Triggers if you want to update a field if you would not be able to use it. You cannot use the other codes that are given to you. The Apex code can get stuck in the metadata but it can be executed when needed.
Hope this helps.
Kindly mark this as solved if the reply was helpful.
Thanks,
Nagendra