5

I have doubt in the Parent-child relationship .Suppose I have scenario where an object is in a relationship with two parent objects. In that relationship if I delete one parent object, will the child object stll exist in the remaining relationship or will it be deleted?

Could you please help me on this?

6

If child record has two lookup (two parents) then if anyone of them is deleted, child will not be deleted.

However, in case of Junction Object where one child has two Master detail relationship (two Parents), even one of them is deleted then Child will be deletd. Check this post on how junction object works in Salesforce ?

| improve this answer | |
0

Few important points (usually interview type Questions of salesforce ):

One Object can have only two Master-Detail relationships. If we delete record A (First Master detail relationship is always primary) – then child record c will be deleted. If we delete record B then in this case also child record C will be deleted. If we delete record c then only C will be deleted , master record will not be deleted. If child C has two Master record A and B, Where A is primary relation then Child record C will inherit the look and feel of Parent object A.

Lookup relationship does not auto-delete any record when the parent or child is deleted.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.