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
mysteriousauramysteriousaura 

Many to Many Relationships between Accounts and Contacts

Hello,

 

I am trying to model many to many relationship with Accounts and Contacts. I know there is a concept of Contact Roles in salesforce but It wont work for me as I need to make sure users with certain profiles can create those specific contact roles.

For eg. a Business Development Mgr can only create Contact/Contact Roles as Business Partners and so on ..

 

Any one has any crazy idea about how to go about doing this?

 

Currently I am accomplishing this using a custom Junction Object but there is this whole concept of Contact being always associated to a particular account otherwise contacts are always Private. I hope it makes sense.

 

Thanks

Cory CowgillCory Cowgill

You will always need to link a Contact to Account. You can't get around this (unless you decide to use Person Accounts, which is a whole ball of wax).

 

You are on the right path using a Junction Object to hold the Many to Many relationships. Using a Junction Object as opposed to SFDC Contact Roles will give you greater flexibility as you have seen.

 

The way I've solved for this is to have one contact to account recrod of type "Belongs To" or "Employee Of" which is kept in sync with the Contact.AccountID field. That way you capture that in the junction records.

 

Nazeer AhamedNazeer Ahamed

Exactly I was in same need and implemented custom junction object, Believe till now (spring 13) that is best apporoach.

Mark StvenMark Stven
I have website related to same day ear wax removal london (https://goo.gl/maps/8H4L52bzde3DGfqg9). And i got this type of issue sometime when my client's detail are compromised by us. Like their name and phone number or relationship status got deadlock due to same name or address. Can anyone help me to sort it out.