function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ABHISHEK CHOPRAABHISHEK CHOPRA 

If an object has two Master Detail relatioship, how to check which one primary and which one secondary ?

If an object has two Master Detail relatioship, how to check which one primary and which one secondary ?
Best Answer chosen by ABHISHEK CHOPRA
Suraj TripathiSuraj Tripathi
Hi ABHISHEK,

If you go to https://workbench.developerforce.com in another tab in the same browser window as your logged in Salesforce instance, you should be able to see which is primary and which is secondary. 

1. Check the "I agree to the terms of service" box and click Login with Salesforce.
2. Choose "Standard and Custom Objects" in the "Jump to" picklist.
3. Choose your object with the 2 master-detail relationships in the "Object" picklist.
4. Expand the "Fields" folder by clicking on the folder icon.
5. Expand both of the master-detail field's folders.
6. Look at the "Relationship Order" parameter for both of the fields.

The field where Relationship Order equals 0 is the Primary and the field where Relationship Order equals 1 is the Secondary. 

I hope this helps!

Regards
Suraj

All Answers

Suraj TripathiSuraj Tripathi
Hi ABHISHEK,

If you go to https://workbench.developerforce.com in another tab in the same browser window as your logged in Salesforce instance, you should be able to see which is primary and which is secondary. 

1. Check the "I agree to the terms of service" box and click Login with Salesforce.
2. Choose "Standard and Custom Objects" in the "Jump to" picklist.
3. Choose your object with the 2 master-detail relationships in the "Object" picklist.
4. Expand the "Fields" folder by clicking on the folder icon.
5. Expand both of the master-detail field's folders.
6. Look at the "Relationship Order" parameter for both of the fields.

The field where Relationship Order equals 0 is the Primary and the field where Relationship Order equals 1 is the Secondary. 

I hope this helps!

Regards
Suraj
This was selected as the best answer
HendrataSFDCHendrataSFDC
Very good to know. Thanks

- Ferdinand