A Salesforce System Administrator at a manufacturing enterprise needs to change an existing Lookup relationship on the custom object Equipment_Maintenance__c (child) to a Master-Detail relationship with the standard Account object (parent) to enforce security inheritance and enable roll-up capabilities. When attempting to convert the field type in Object Manager, the system throws an error and prevents the modification. What prerequisite step must be completed before Salesforce will allow converting this Lookup relationship to a Master-Detail relationship?
- Populate a valid Account record reference in the lookup field for every existing Equipment_Maintenance__c record.Answer
- BCreate a roll-up summary field on the Account object referencing Equipment_Maintenance__c prior to altering the relationship field type.
- CDelete all parent Account records that do not currently have associated Equipment_Maintenance__c records to reset deletion cascade settings.
- DChange the Organization-Wide Default (OWD) sharing setting of Equipment_Maintenance__c to Controlled by Parent prior to conversion.
Answer
Populate a valid Account record reference in the lookup field for every existing Equipment_Maintenance__c record.
You can convert a Lookup relationship to a Master-Detail relationship only if the lookup field on all existing records contains a value. If any child record has an empty lookup field, Salesforce rejects the relationship type conversion until every record has a designated parent.
Step-by-Step Solution
Key Concept
Converting Lookup Relationships to Master-Detail Relationships
Estimated Time:1m 30s