Loading
Salesforce now sends email only from verified domains. Read More

Mass update Territory on Opportunity records via Data Loader

Publish Date: Apr 2, 2026
Description

If you enable ‘Enterprise Territory Management’ in your organization, the ‘Territory’ field will become available in the ‘Opportunity’ object. This field can be updated with Data Loader, especially if it was not automatically updated after running territory assignment rule.

 

Scenario: "For example, after enabling Enterprise Territory Management, a sales ops admin needs to assign 10,000 Opportunities to newly created territory records, too many to update manually.

Resolution

  
A.    Prepare a CSV file for update. The CSV file must contain the following fields:  

  • OpportunityId: Id of the Opportunities to be updated
  • Territory2Id: This is the Id of the territory assigned to the opportunity. To find these values, a System Administrator can go to 'Territory Model' in Setup, click on 'View Hierarchy' and finally click on the territory. The Territory ID can be viewed on the URL and would start with '0MI'

B.    Use Data Loader to run an update on Opportunities

  1. Log in to Data Loader.
  2. Click Update.
  3. Select Opportunities from the list of available Salesforce objects.
  4. Click Browse and upload the CSV prepared in Step A.
  5. Click Next.
  6. Click Create or Edit Map and map the fields accordingly.
  7. Click OK and Next, then choose a directory file for the success/error result.
  8. Click Finish.
Knowledge Article Number

000384024

 
Loading
Salesforce Help | Article