Salesforce Platform Developer I (legacy) — Question 257
Universal Containers tracks customer complaints in a custom object, Complaint__c, that has a Master-detail relationship to the Contact that made the complaint.
Which field is needed to display the date of the most recent Complaint__c on the Contact's detail page?
Answer options
- A. Roll-up summary field on Contact of the MAX Created Date of a Complaint__c
- B. Roll-up summary field on Contact of the MIN Created Date of a Complaint__c
- C. Formula field on Contact of the MAX Created Date of a Complaint__c
- D. Formula field on Contact of the MIN Created Date of a Complaint__c
Correct answer: A
Explanation
The correct answer is A because a roll-up summary field can aggregate data from related records and the MAX function will return the most recent Created Date. Options B, C, and D are incorrect as they either look for the earliest date (Option B) or use a formula field which cannot aggregate in the same manner as a roll-up summary field (Options C and D).