Ir al contenido

Account Relationship Data Sharing Rules

Esta página aún no está disponible en tu idioma.

Module 5 of 6 in the chapter Sharing Sets, Share Groups and Data Sharing for High-Volume Users, chapter 15 of Securing Salesforce: Sharing and Visibility. Each module stands on its own.

The question this module answers: One outside company needs to see another outside company’s records. Both are your partners. How do you share between them, account to account?

Modules 1 to 4 were about the cheap seats: users with no role and no share table. This module moves forward in the stadium, to the seats with cushions: Customer Community Plus and partner users (chapter 14, module 3). They have roles. They have the share table. And sometimes they need something the earlier tools don’t give them.

The kitchen equipment maker doesn’t only sell straight to restaurants. It also sells through distributors, and it uses independent installers to put the equipment in. Both are partner accounts, with partner users on the site.

A distributor wins a big order for a new restaurant. The installer has to plan the installation, so the installer’s people need to see that distributor’s opportunities. Not every distributor’s. That one.

How do we do that? An owner-based sharing rule from the distributor’s partner roles to the installer’s partner roles would work for one pair. Now picture forty distributors and sixty installers, pairing up and splitting apart every quarter. That’s a lot of rules, written in Setup, for something the business changes every week.

In my video I called the answer a powerful tool: the account relationship data sharing rule. It’s way 22 of the 25 (chapter 5, module 8).

Account relationships and their data sharing rules “give you granular control over how account information is shared.” The records they share, such as cases, opportunities and contacts, don’t have to be owned by a user of that account: “they just have to be associated with it” (Account Relationships and Account Relationship Data Sharing Rules (opens in a new tab), Salesforce Help, checked 2026-11-26).

There are two pieces, and it helps to keep them apart:

  • The rule says what is shared and how much. “The data sharing rule defines the relationship type, the information that is shared, and the record access given to the account that is gaining access” (same page). You build a few of these in Setup.
  • The relationship says between whom. “The account relationship comprises the account that is sharing information, the account that is accessing those records, and the type of relationship they have” (same page). It’s a record, and you create one for each pair of accounts.

The two meet on one field: the Account Relationship Type, a picklist such as Installer or Distributor. A relationship of type Installer uses the rules of type Installer. That’s the design: write the rule once, then add or remove pairs as records, not as Setup changes.

The fields on the rule (Configure Account Relationship Data Sharing Rules (opens in a new tab), Salesforce Help, checked 2026-11-26):

  • Account Relationship Type: the type that ties the rule to relationships.
  • Access Level: “Read and Write are the only access levels available.”
  • Object Type: the records you’re sharing. The rules “can apply to; accounts, campaigns, cases, contacts, custom objects, leads, opportunities, orders, partner fund allocations, partner fund claims, partner fund requests, and partner marketing budgets.”
  • Account To Criteria Field: which of the giving account’s records go. “Use only owner and account lookup fields.”
  • Advanced Formula: “Static formula criteria that can be applied to the data sharing rule to further refine how objects are shared.”

The criteria field is the one to think about. Salesforce explains the two kinds (same page):

  • An owner lookup. “If they look up to a user, then the rule applies to the specified object’s records owned by the Account To’s portal users.” So only the records the distributor’s own partner users own.
  • An account lookup. “If it looks up to an Account, then the rule applies to the object’s records with the Account To name listed as their account.” So every record tied to the distributor, whoever owns it, including records your own people own.

For our installer, the opportunities are often owned by the kitchen equipment maker’s channel manager, with the distributor as the partner account. An owner lookup would miss them. So the rule is: type Installer, Opportunity, Partner Account as the criteria field, Read. And if the installer only needs the big ones, the advanced formula narrows it further.

“When you’ve created an account relationship data sharing rule, assign it to an account relationship to begin sharing” (Create an Account Relationship (opens in a new tab), Salesforce Help, checked 2026-11-26). You create it from the partner account’s Account Relationship related list.

Now read the two account fields slowly, because they catch everyone (same page):

  • Account To: “The account that is giving access to their records to another account.”
  • Account From: “The account that is gaining access to another account’s data.”

It reads backwards to most people. The records go from Account To, to Account From. I’d remember it this way: Account From is where the request comes from. The installer asks; the distributor gives. Distributor in Account To, installer in Account From, type Installer.

And the shared records show up where the installer works: “Once an account relationship data sharing rule is in effect, the shared information filters into the object list view of the account gaining access (Account From)” (Account Relationships and Account Relationship Data Sharing Rules (opens in a new tab)).

Account relationship data sharing, one pair of partners Account relationship data sharing, one distributor and one installer. The distributor is Account To: it gives its records. The installer is Account From: it gets access. Between them, an account relationship of type Installer, one record for this pair. The data sharing rule of type Installer says what goes and how much: Opportunity, chosen by Partner Account, Read; it applies to every relationship of that type. The distributor's opportunities, the ones with the distributor as partner account, are what the installer sees. Footnote: the rule says what and how much; the relationship says between whom; the type joins them. {"author": "Steve Simpson", "blueprint": "1.0.0", "builder": "standard 1.59.0", "built": "2026-11-20", "id": "DGM-SVA-SSG-05", "rights": "\u00a9 2026 Twinshark LLC. All rights reserved.", "template": "object-model/conceptual 1.8.0", "theme": "stevetecharc 1.4.0"} gives through gets through applies to partners on Distributor Account To: gives Account Relationship type Installer, one per pair Installer Account From: gets access Opportunity the distributor's deals Data Sharing Rule Opportunity · Partner Account · Read The rule says what and how much; the relationship says between whom; the type joins them. exactly one zero or one one or many zero or many © 2026 Twinshark LLC · stevetecharc.com
Click to enlarge

It can’t be turned off. You enable account relationships in Digital Experiences Settings, and “After you enable account relationships in your org, you can’t disable it” (Configure Account Relationship Data Sharing Rules). That’s not a reason to avoid it. It’s a reason to decide on purpose, and to try it in a sandbox first.

Who it reaches. “Account relationships only share data with Partner or Customer Community Plus users” (Best Practices for Account Relationships (opens in a new tab), Salesforce Help, checked 2026-11-26). Not the cheap seats; the earlier modules are for them.

What it can’t share. Salesforce’s considerations page (Considerations When Using Account Relationships and Data Sharing Rules (opens in a new tab), Salesforce Help, checked 2026-11-26) lists several edges worth knowing by heart:

  • “Account Relationships don’t share data owned by a queue.”
  • “Account relationships don’t share data from High Volume Portal Users.”
  • “Account relationships can’t share data with accounts that use account role optimization.” If you turned on account role optimization for an account (chapter 14, module 5), it can’t receive these shares.
  • “If the organization-wide default sharing setting an object is set to Controlled by Parent, the object’s record data can’t be shared via an Account Relationship Data Sharing rules.”
  • “If sharing isn’t enabled for orders, then you can’t create Account Relationship Data Sharing rules for them.”

What you can’t change later. Also from the considerations page:

  • “Only one sharing rule can contain the same Account Relationship Type and Object Type field values.” One Installer rule for opportunities, not two.
  • “After an account relationship is saved, only its name can be updated. To make further changes, delete the account relationship and create a new one.”
  • “You can’t replace, delete, or deactivate an Account Relationship Type picklist value used in an account relationship or Account Relationship Data Sharing rule.”
  • “An account that is part of an account relationship can’t be deleted or merged.” Tell your data team before their next round of duplicate merging.

Not the same as a sharing rule. “Sharing rules follow our standard sharing rule procedures and aren’t the same as Account Relationship Data Sharing rules,” and “Deferred Sharing rules don’t affect Account Relationship Data Sharing rules” (same page). So deferring sharing calculations during a big change won’t hold these back.

Salesforce’s best practices are about performance (Best Practices for Account Relationships, same page):

  • “If possible, load your data before you set up account relationship data sharing rules.” If you have to load after, “load no more than 1 million records per day.”
  • “Avoid bulk Contact reparenting operations.”
  • “Limit updates to account relationship data sharing rules that are being used by multiple account relationships,” and space them out; “shared data may not be immediately available after you make the updates.”
  • “For optimal data processing, position users who own many records at the top of an external role hierarchy.”
  • “Before you put your account relationship data sharing rules into production, test them in a Sandbox.”

One thing to know: the pages don’t agree on the order. The configure page has you create the rule, then the relationship. The best practices page says “Create the account relationship before creating account relationship data sharing rules.” For a first setup with little data, the configure page’s order is how the screens work. For a big org, the best practices are about not recalculating more than you have to; test both in a sandbox with your own volumes.

With relationships as records, “who can see whose data” is a report away. “Create a custom report using the Account Relationship object to track your account relationships. Once you’ve created the report, share your information in a dashboard” (Create Reports for Account Relationships (opens in a new tab), Salesforce Help, checked 2026-11-26). Build it on day one. When an auditor asks which partners can see each other’s opportunities, that report is your answer, and chapter 13’s evidence (chapter 13, module 4).

Test knowledge. Know the two pieces: the account relationship data sharing rule (relationship type, object, Account To criteria field, Read or Write, optional static formula) and the account relationship (Account To gives, Account From gets, matched by Account Relationship Type). Know owner lookup versus account lookup in the criteria field. Know that enabling account relationships can’t be undone; that they share only with Partner and Customer Community Plus users; and that they don’t share queue-owned records, high-volume users’ records, Controlled by Parent objects, or with accounts using account role optimization. Know one rule per relationship type and object, that a saved relationship can only be renamed, and that an account in a relationship can’t be deleted or merged. A likely area, not a known question.

  • Whether partner companies really need to see each other’s records, and whether it’s for a few fixed pairs (a sharing rule may do) or many pairs that change (account relationships).
  • Whether to enable account relationships at all, knowing it can’t be turned off; tried in a sandbox first.
  • For each object, owner lookup or account lookup, Read or Write, and a static formula if only some records should go.
  • The relationship types, chosen with care, because a used type can’t be retired.
  • Who creates and ends account relationships, and how the report on them is reviewed.
  • Which accounts will use account role optimization, since those can’t receive these shares.

Beyond the exam: what AI changes. An account relationship puts one company’s records in front of another company’s users. A partner’s agent, or your own agent answering a partner, sees those records as that partner’s users do. Before an agent works for partners, run the account relationship report and read it as the agent would: every pair, every object, every access level. A relationship that someone forgot to end is now an agent that keeps answering questions about another company’s deals. Chapter 20 covers agents.