Overview:
Data loaded Account Territory Loader (ATL) records are not working properly. The ObjectTerritory2Association (OT2A) records are not deleted or created after the insert or upsert data load job.
Root Cause:
The ATL records are not updated due to the large data loading batch size. If the batch size is larger than 20, a trigger copies the territory from the ATL fields and causes the OT2A records to not fire. This is because the Salesforce query limit is already reached.
Solution:
Use a smaller batch size during the data loading. The optimal batch size is approximately 10-20.
Related Documentation:
- CRM help: Territory Management using ATL
- Salesforce guide: Execution Governors And Limits