Soru

Zorluk: KolayObject Relationships (Lookup, Master-Detail, Many-to-Many)

An administrator is establishing a relationship between a parent custom object, Project_Plan__c, and a child custom object, Project_Task__c. The business requires that deleting a project plan automatically deletes all related project tasks, and management wants to calculate the total estimated task hours on the project plan record.

Which two statements describe the capabilities and behaviors of implementing a Master-Detail relationship for this requirement? (Choose 2 answers)

  1. A Roll-Up Summary field can be created on Project_Plan__c to calculate aggregate values from related Project_Task__c records.Cevap
  2. Deleting a Project_Plan__c record automatically deletes all associated Project_Task__c records.Cevap
  3. C
    A Lookup relationship should be used instead because Lookup relationships natively support Roll-Up Summary fields on the parent object.
  4. D
    Deleting a Project_Plan__c record leaves related Project_Task__c records active and sets their parent lookup field to null.

Cevap

The correct statements are that a Roll-Up Summary field can be created on the parent object to aggregate child record values, and deleting a parent record automatically deletes all associated child records.
In Salesforce, Master-Detail relationships provide tight coupling between master and detail records. This enables native Roll-Up Summary fields on the master object to aggregate child values (such as total hours) and enforces cascading deletion, which automatically deletes detail records when their parent master record is deleted.

Adım Adım Çözüm

1
Analyze the business requirements for record deletion behavior and data aggregation.
Requirements specify cascade deletion of child records and roll-up calculations on the parent record.
Master-Detail relationships enforce cascading deletion and natively enable Roll-Up Summary fields on the master object.
2
Evaluate relationship capabilities between Lookup and Master-Detail types.
Lookup relationships do not natively support Roll-Up Summary fields and do not automatically cascade delete records by default.
Master-Detail is the correct architecture to meet both requirements natively.

Anahtar Kavram

Master-Detail Relationship Capabilities and Lifecycle Inheritance
Tahmini Süre:1m 0s
Bu soruyu puanla