Loading
Salesforce now sends email only from verified domains. Read More
Manage Users and Data Access
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Defer Sharing Rule Calculations

          Defer Sharing Rule Calculations

          If you’re making a large number of changes that affect sharing rules, including changes to sharing rules, roles, territories, or public groups, you can temporarily suspend automatic sharing rule calculations and resume them after you finish your updates. You must resume calculations and do a full sharing rule recalculation, or you can experience sharing inconsistencies in your records.

          Required Editions

          Available in: both Salesforce Classic and Lightning Experience

          Available in: Professional, Enterprise, Performance, Unlimited, and Developer Editions

          See Sharing Rule Considerations for more information on availability.

          User Permissions Needed
          To defer (suspend and resume) and recalculate sharing rules:

          Manage Users

          AND

          Manage Sharing Calculation Deferral

          When you make any of these changes, sharing rules are automatically recalculated to add or remove access as necessary:

          • Change an organization's default sharing model
          • Create, edit, or delete sharing rules
          • Create or transfer any records
          • Update public group members
          • Create or activate a user
          • Change users’ roles or update the role hierarchy
          • Add or remove users from territories
          • Reparent territories
          • Make changes to roles, territories, or public groups involved in sharing rules

          If any of these changes affect large groups of users or related features, your updates can cause performance issues or sharing rule calculation timeouts. You can temporarily defer sharing rule calculations before you make your changes. After you finish your updates, you must resume sharing rule calculations and do a full sharing rule recalculation. Review Considerations for Making Sharing Updates before deferring sharing rule calculations.

          Note
          Note If you defer sharing rule calculations, only updates that involve sharing rules, whether directly or indirectly, are deferred, while other sharing-related changes are still processed immediately. To give a few examples, if you create sharing rules or update roles that are referenced in sharing rules, the resulting recalculations are paused. However, if you create manual shares, update teams or queues, or update roles that aren’t referenced in any sharing rules, those changes are still evaluated immediately. These calculations that can't be suspended can take significant time to process based on the org's settings and data volume.

          Group membership locking can also still occur while sharing calculations are deferred.

          We recommend that you resume sharing calculations immediately after making your changes, and then start the full sharing rule recalculation as soon as possible during a period of low activity. By resuming sharing calculations immediately, new updates are processed immediately, meaning there are fewer changes that must be recalculated. Completing the full sharing recalculation in a timely manner then ensures that record access behaves as expected without significant lag time.

          Note
          Note The defer sharing calculation feature isn't enabled by default. To enable it for your organization, contact Salesforce Customer Support.
          1. From Setup, in the Quick Find box, enter Defer Sharing Calculations, and then select Defer Sharing Calculations.
          2. In the Sharing Rule Calculations related list, click Suspend.
          3. Make changes to sharing rules, roles, territories, or public groups participating in sharing rules.
          4. To enable sharing rule calculations again, click Resume.
          5. To manually recalculate sharing rules, click Recalculate.
          Important
          Important After you resume sharing rule calculations, you must click Recalculate to do a full sharing rule recalculation. Otherwise, changes that you made while calculations were suspended aren’t reflected in record access.

          When sharing is recalculated, Salesforce also runs all Apex sharing recalculations.

           
          Loading
          Salesforce Help | Article