Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.
exam questions

Exam CRT-450 All Questions

View all questions & answers for the CRT-450 exam

Exam CRT-450 topic 1 question 255 discussion

Actual exam question from Salesforce's CRT-450
Question #: 255
Topic #: 1
[All CRT-450 Questions]

A developer created a new after insert trigger on the Lead object that creates Task records for each Lead.

After deploying to production, an existing outside integration that inserts Lead records in batches to Salesforce is occasionally reporting total batch failures being caused by the Task insert statement. This causes the integration process in the outside system to stop, requiring a manual restart.

Which change should the developer make to allow the integration to continue when some records in a batch cause failures due to the Task insert statement, so that manual restarts are not needed?

  • A. Deactivate the trigger before the integration runs.
  • B. Use a try-catch block after the insert statement.
  • C. Use the Database method with allOrNone set to false.
  • D. Remove the Apex class from the integration user’s profile.
Show Suggested Answer Hide Answer
Suggested Answer: C 🗳️

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
SanjeevOnForce
1 year ago
CCCCCCCCCCCCCCCC
upvoted 1 times
...
tMana
1 year, 8 months ago
It is C
upvoted 4 times
...
moorer
1 year, 10 months ago
Selected Answer: C
isn't it supposed to be C
upvoted 4 times
wlthorn
1 year, 8 months ago
C. Use the Database method with allOrNone set to false. To prevent the outside integration from stopping when errors occur during a batch insert operation, the developer should use the Database method with allOrNone set to false. When allOrNone is set to false, the database operation will still execute for the records that did not encounter an error, even if some records failed.
upvoted 2 times
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...