Loading

Load Opportunity Product records with Salesforce Data Loader

Date de publication: Apr 2, 2026
Description

Data Loader can be used to import Opportunity Product (or OpportunityLineItem) records. 

 

Scenario:

For example, a sales ops admin needs to bulk-load 500 Opportunity Products into existing Opportunities after migrating from a legacy CRM. The CSV must include OpportunityID, PricebookEntryID, and UnitPrice columns.

Résolution

The video above (runtime ~5 minutes) walks through preparing the CSV file and running the Data Loader insert for OpportunityLineItem records, including how to retrieve PricebookEntry IDs.



To get started, prepare a CSV template with the following columns:

 

  • OpportunityID
  • PricebookEntryID
  • Product2ID
  • Quantity
  • TotalPrice (Quantity x UnitPrice) or UnitPrice

To get the OpportunityID, navigate to the Opportunity record and copy the ID in the page URL, or use Data Loader to export records from the Opportunity object if you're working with more than one Opportunity. Include the ID, Opportunity Name, and any other fields that will help to identify the correct Opportunities. 


To get the values for PricebookEntryID and Product2ID, export them from "Price Book Entry (PricebookEntry)" object using the Data Loader, and select the fields ID, Product2ID, and any other fields that will help to identify the correct Product. The ID fields are equivalent to the PricebookEntryID .

If you have any additional information for the import, you can add new columns to the .csv file to reflect the fields and data. 

Once file is saved as a .csv file, perform an import using Data Loader:

 
  1. Open Data Loader
  2. Click on Insert and log in with your organization's credentials.
  3. Select the Show all Salesforce objects
  4. Select the Opportunity Product (OpportunityLineItem)
  5. Click Browse to select where the CSV that you prepared 
  6. Click Next, click OK.
  7. Click Create or Edit a Map.
  8. Click Auto-Match Fields to Columns or drag the field from the top panel to the corresponding field on the bottom panel then click OK.
  9. Click Next.
  10. Click Browse and select where the result will be saved.
  11. Click Finish, click OK.
Numéro d’article de la base de connaissances

000382941

 
Chargement
Salesforce Help | Article