An administrator at a renewable logistics firm is designing a custom object named Vehicle_Maintenance__c to track service logs for fleet vehicles managed on the standard Asset object. The business requires that deleting an Asset record automatically removes all of its associated Vehicle_Maintenance__c logs. Additionally, management must be able to calculate total maintenance costs directly on the parent Asset record using a native Roll-Up Summary field. Which relationship field type should the administrator create on the Vehicle_Maintenance__c object to fulfill these requirements?
- A Master-Detail relationship field referencing the Asset objectCevap
- BA Lookup relationship field referencing the Asset object
- CA Lookup relationship field with cascade delete enabled referencing the Asset object
- DA Hierarchical relationship field referencing the Asset object
Cevap
A Master-Detail relationship field referencing the Asset object is required to support both cascade deletion and Roll-Up Summary fields on the parent object.
A Master-Detail relationship field created on the child object inherently satisfies both core business requirements: it enforces tight life-cycle binding (cascading record deletion from parent to child) and enables standard Roll-Up Summary fields on the parent object to aggregate numeric data from child records.
Adım Adım Çözüm
Anahtar Kavram
Master-Detail vs. Lookup Relationship Capabilities