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 11 discussion

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

A developer working on a time management application wants to make total hours for each timecard available to application users. A timecard entry has a Master-
Detail relationship to a timecard.
Which approach should the developer use to accomplish this declaratively?

  • A. A Visualforce page that calculates the total number of hours for a timecard and displays it on the page
  • B. A Roll-Up Summary field on the Timecard Object that calculates the total hours from timecard entries for that timecard
  • C. A Process Builder process that updates a field on the timecard when a timecard entry is created
  • D. An Apex trigger that uses an Aggregate Query to calculate the hours for a given timecard and stores it in a custom field
Show Suggested Answer Hide Answer
Suggested Answer: B 🗳️

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
SS1121
4 months, 3 weeks ago
Selected Answer: B
B is correct, as option A is not declarative.
upvoted 2 times
...
PriyankN
8 months, 1 week ago
B is correct
upvoted 2 times
...
HRVMMRVH
1 year, 2 months ago
Certainly not A, since a declarative solution is needed. It should be B. Hours can be stored as number field on Timesheet entry records.
upvoted 3 times
...
CSYU
1 year, 4 months ago
Selected Answer: A
The answer is def A Although it's a Master-detail relationship, we can't use a roll-up summary field on date/time field when using SUM type. It's available only when using MAX/MIN as described in the Help page. When the developer wants to know total hours, he can use an Apex code and as the total hours doesn't have to be saved in DB in this case, so the answer is A.
upvoted 1 times
9868452
1 month, 1 week ago
Yes, that's true, but in the scenario it doesn't mention that the field is a date/time type field either. And someone has also pointed out that the answer needs to be a declarative one according to the question given - visualforce pages are programmatic solutions.
upvoted 1 times
...
CSYU
1 year, 4 months ago
When it comes to the field type is Number, the answer can be B. The question is too abstract...
upvoted 2 times
...
mariamarlenepereira9
10 months ago
Total (number of) hours = SUM, so this can be achieved using a roll up summary field
upvoted 1 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 ...