Thursday, October 13, 2016

Salesforce: Contact Sharing Setting

When Account sharing rule is Private, options for Contact sharing will be: Private or Controlled by Parent only.

Use case with following sharing setting:
- Account: Private
- Contact: Controlled by Parent

For Account that user suppose do not have access to, but if any Contacts that user owned are linked to the Account. Contact Owner will be able to access the Account (read-only). But, this does NOT apply for indirect contact linked to Account via Related Contact to Multiple Account relationship.

Sample: screenshot below is all accounts visible to user:

and this is all contacts visible to user:

When user received a contact link to the account that user has no access "Google", in this sample "Mann, Saman", user will be able to see that contact. Furthermore, if the Account have multiple Contacts, user will be able to see all Contacts for that Account, in sample below "Li. Linda", even user does not own the contact:

Because now user own a contact Mann, Saman which is linked to Google account, user will be able to read Google account, furthermore user will also able to access Li, Linda although not owned by the user, because user have read access to the Account.

1. Contact Owner will NOT able to link his/her Contact to an Account if the user do not have read access. The same also applicable for Related Contact to Multiple Account feature.

2. If your Organization-Wide Default for Contact is set to Controlled by Parent, you will not see Sharing button in Contact page layout.

3. All access to the contact is determined by the user's accessibility to the Account for that Contact.
But, since Contact is a special standard object with owner field (different with normal M-D relationship), contact have Owner. Even Contact sharing setting is set to Controlled by Parent, contact owner will be able to edit contact, and this would not related to the user accessibility to the Account.

Side notes related to Opportunity:
If Account is Private, this will cause Opportunity become Private.
The same with Contact, Opportunity Owner will be able to access (read-only) Account because Opportunity is linked to Account.