New Year Sale 2026! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Salesforce CCM-101 Exam - Topic 8 Question 24 Discussion

Actual exam question for Salesforce's CCM-101 exam
Question #: 24
Topic #: 8
[All CCM-101 Questions]

The following sample code is NOT providing the desired results. The Digital Developer needs to add an entry to the logs to debug the problem.

Which statement correctly adds a log entry?

Show Suggested Answer Hide Answer
Suggested Answer: A

Contribute your Thoughts:

0/2000 characters
Erick
3 months ago
I doubt option C is correct; it’s more for faults, not errors.
upvoted 0 times
...
Naomi
3 months ago
I'm surprised there's no option for a warning log here.
upvoted 0 times
...
Amie
4 months ago
Wait, isn't option A also a valid way to log?
upvoted 0 times
...
King
4 months ago
Definitely agree with you, D seems most appropriate!
upvoted 0 times
...
Dulce
4 months ago
I think option D is the right choice for logging errors.
upvoted 0 times
...
Lajuana
4 months ago
I have a feeling that Logger.fault is more for critical issues, so I’m leaning towards Logger.error as well, but I’m not completely certain.
upvoted 0 times
...
Beula
4 months ago
I’m a bit confused about Logger.getErrorLog().log; it seems like it could work, but I don’t recall using that method in our exercises.
upvoted 0 times
...
Troy
5 months ago
I practiced a similar question where we had to log errors, and I feel like Logger.error might be the best option since it seems more appropriate for this situation.
upvoted 0 times
...
Shad
5 months ago
I think I remember that Logger.exception is used for catching exceptions, but I'm not sure if that's the right choice here.
upvoted 0 times
...
Benedict
5 months ago
I'm feeling pretty confident about this one. The prompt clearly states that it may take several months for the insurer to investigate and establish a case reserve, so I think the answer is True.
upvoted 0 times
...
Janey
5 months ago
Aftersales Support feels out of place here, right? I can't recall seeing it linked to migration strategies in my studies.
upvoted 0 times
...
Dahlia
5 months ago
I'm pretty sure the answer is C. I remember learning that you can make a non-reusable copy of a reusable transformation by selecting it and holding down Ctrl while dragging it into the mapping.
upvoted 0 times
...
Teresita
9 months ago
D is the way to go. Though I'm curious, why is the code not providing the desired results in the first place? Gotta love those tricky certification questions!
upvoted 0 times
Allene
8 months ago
D is the way to go. Though I'm curious, why is the code not providing the desired results in the first place? Gotta love those tricky certification questions!
upvoted 0 times
...
Olen
8 months ago
D) Logger.error('Unable to find Apple Pay payment instrument for order.'+paymentInstruments);
upvoted 0 times
...
Ashleigh
8 months ago
C) Logger.fault('Unable to find Apple Pay payment instrument for order.'+paymentInstruments);
upvoted 0 times
...
Chandra
8 months ago
User3: Maybe there's an issue with the paymentInstruments variable.
upvoted 0 times
...
Beatriz
8 months ago
User2: I agree, D is the correct option.
upvoted 0 times
...
Judy
8 months ago
B) Logger.getErrorLog().log('Unable to find Apple Pay payment instrument for order.'+paymentInstruments);
upvoted 0 times
...
Agustin
8 months ago
User1: D) Logger.error('Unable to find Apple Pay payment instrument for order.'+paymentInstruments);
upvoted 0 times
...
Novella
8 months ago
A) Logger.exception('Unable to find Apple Pay payment instrument for order.'+paymentInstruments);
upvoted 0 times
...
...
Amie
10 months ago
Haha, the question is so straightforward. If you can't figure out the right way to log an error, you might as well just give up on this exam!
upvoted 0 times
...
Glory
10 months ago
I think option B is correct. Logger.getErrorLog().log('Unable to find Apple Pay payment instrument for order.'+paymentInstruments) seems more comprehensive than just using Logger.error().
upvoted 0 times
Noble
8 months ago
Logger.getErrorLog().log() seems like the right way to go in this situation.
upvoted 0 times
...
Whitney
9 months ago
I think option B is the most appropriate one for debugging the issue.
upvoted 0 times
...
Detra
9 months ago
I would go with option B as well, it seems like the most detailed option.
upvoted 0 times
...
Sharika
9 months ago
I agree, option B looks like the best choice for adding a log entry.
upvoted 0 times
...
Deeanna
9 months ago
I think option B is the most appropriate for adding a log entry.
upvoted 0 times
...
Jeanice
9 months ago
I agree, option B looks like the best choice.
upvoted 0 times
...
...
Claribel
10 months ago
Why do you think D is the correct answer?
upvoted 0 times
...
Providencia
10 months ago
I disagree, I believe the correct answer is D.
upvoted 0 times
...
Claribel
11 months ago
I think the answer is B.
upvoted 0 times
...
Serita
11 months ago
The correct answer is D. Logger.error('Unable to find Apple Pay payment instrument for order.'+paymentInstruments). This is the appropriate way to log an error message in the code.
upvoted 0 times
Novella
9 months ago
I'm positive, it's D) Logger.error.
upvoted 0 times
...
Owen
9 months ago
Are you sure? I believe it's B) Logger.getErrorLog().log.
upvoted 0 times
...
Glennis
10 months ago
No, the correct answer is D) Logger.error.
upvoted 0 times
...
Shoshana
10 months ago
I think the correct answer is A) Logger.exception.
upvoted 0 times
...
...
Gerald
11 months ago
I'm not sure, but I think B could also be a valid option.
upvoted 0 times
...
Ryan
11 months ago
I agree with Shala, Logger.error seems like the right choice.
upvoted 0 times
...
Shala
11 months ago
I think the correct answer is D.
upvoted 0 times
...

Save Cancel