Loading

Recommended Salesforce Object Load Order for Large Data Loads and Data Migrations

Publiseringsdato: May 19, 2026
Beskrivelse

When performing large data loads or migrating data into Salesforce, loading Salesforce objects in the correct sequence prevents relationship errors and data integrity issues. Salesforce objects are linked through lookup and master-detail relationships — parent records must exist before child records that reference them are created.
For example, Accounts must be loaded before Contacts because a Contact record contains a lookup field that references an Account. If Contacts are loaded first, the Account lookup will fail.
This article provides the recommended load order for standard Salesforce objects and notes on Custom Objects and Activities.

Løsning

Standard Salesforce Object Load Order

Load objects in the following sequence to respect parent-child relationships:

  1. Accounts — Top-level parent object; most other records relate to Accounts.
  2. Contacts — Related to Accounts (lookup relationship to Account).
  3. Opportunities — Related to Accounts and Contacts.
  4. Products — Independent; no parent dependency on records above.
  5. Opportunity Line Items — Related to Opportunities and Products (requires both to exist).
  6. Cases — Related to Contacts (and optionally Accounts).
  7. Leads — Typically independent; no parent dependency.
  8. Campaigns — Independent; no parent dependency.
  9. Campaign Members — Related to Campaigns, Contacts, and Leads (all three must exist first).
  10. Contracts — Related to Accounts and Contacts.
  11. Assets — Related to Accounts, Contacts, Cases, and Products (all must exist first).

 

Notes on Custom Objects and Activities

  • Custom Objects: The load order for custom objects depends on your specific Salesforce implementation and the lookup/master-detail relationships you have configured. Map your custom object relationships and load parent objects before child objects.
  • Activities (Tasks and Events): Activities are the last objects to load. They can be related to most standard and custom objects. Load all related parent objects before loading Activities to ensure relationship lookups succeed.
Knowledge-artikkelnummer

000384386

 
Laster
Salesforce Help | Article