nerdexam
Salesforce

PDII · Question #405

A company wants to incorporate a third-party web service to set the Address fields when an Account is inserted, if they have not already been set. What is the optimal way to achieve this?

The correct answer is D. Create an after insert trigger, call an @future(callout=true) method from it, and make the callout. See the full explanation below for the reasoning.

Question

A company wants to incorporate a third-party web service to set the Address fields when an Account is inserted, if they have not already been set. What is the optimal way to achieve this?

Options

  • ACreate a Process, call an Apex @future(callout=true) method from it, and make the callout from
  • BCreate a Process, call an Apex @InvocableMethod from it, and make the callout from that Apex
  • CCreate an after insert trigger, call an Apex @InvocableMethod method from it, and make the
  • DCreate an after insert trigger, call an @future(callout=true) method from it, and make the callout

How the community answered

(40 responses)
  • A
    13% (5)
  • B
    8% (3)
  • C
    3% (1)
  • D
    78% (31)

Community Discussion

No community discussion yet for this question.

Full PDII Practice