Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Salesforce Exam PDI Topic 6 Question 81 Discussion

Actual exam question for Salesforce's Platform Developer I exam
Question #: 81
Topic #: 6
[All Platform Developer I Questions]

When the code executes, a DML exception is thrown.

How should a developer modify the code to ensure exceptions are handled gracefully?

Show Suggested Answer Hide Answer
Suggested Answer: C

Contribute your Thoughts:

Karl
4 months ago
Removing null items from the list? That's just avoiding the problem, not solving it. I'm all about C!
upvoted 0 times
...
Glynda
4 months ago
Change Data Capture? Nah, that's overkill for this use case. Gotta go with option C.
upvoted 0 times
Karon
3 months ago
User 2: Yeah, a try/catch block will handle the exceptions gracefully.
upvoted 0 times
...
Caprice
3 months ago
User 1: I agree, option C is the way to go.
upvoted 0 times
...
...
Tanja
4 months ago
Implementing upsert seems like a band-aid solution. I'd go with the try/catch block to properly address the exception.
upvoted 0 times
...
Vilma
4 months ago
Haha, I bet the exam question writer is sitting back and laughing at all the silly answers we're coming up with. Gotta love these tricky questions!
upvoted 0 times
Peggie
4 months ago
A) Implement the upsert DML statement.
upvoted 0 times
...
Na
4 months ago
C) Implement a try/catch block for the DML.
upvoted 0 times
...
...

Save Cancel