function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
tony2009tony2009 

Import records with Record Type

Hi Guys,

 

I am trying to use data loader command line to import data from other system to Salesforce for daily synchronization.

 

In old system, the account table come with role table(many-to-one, child-parent relationship). But in salesforce,  it is designed by account object with corresponding record type.

 

According to the data load guide, I can specified the extenal id on the salesforce destination object, then the data could be imported with the relationships between the account and role.

 

But it seems I cannot add new external Id field on the record type object. How can I transfer the account and role from orignal system to salesforce?

 

Since we are still using the old system, the new roles may be inserted into the system. In this case, we cannot manually specify the record type id on the csv file.

 

Any help would be greatly appreciated.

 

 

VPrakashVPrakash

 

 

  • Export Recordtype file  using the data loader -- Export recordtypeids for Account object from salesforce and add a column Role in this file.
  • update the column with role names from the other system.like as follows 

recordtypeid         Role
RT1                        role1
RT2                        role2

 

  • Source load file will have the accounts with roles, use VLOOKUP in excel to get the corresponding recordtypeid from the Recordtype file into the source load file.
  • Once the Recordtypeids are in the source file you can insert the source file using the dataloader into salesforce account object.

 

tony2009tony2009

Thanks VPrakash,

 

This is greate solution for manully data importing.

 

But I am using the command line data loader to develop an automate scripting for this process. And the old system is still using, which means the new roles (record types) can be inserted  by user. In the case, I cannot  hard code the record id in my automate scripting code. and this script also need to import data for other instances.

 

Is there any way I could import the data like normal relationships (for example: Account and Contact) upload via extenal id or something else?

 

 

 

 

Shahejan Shaikh 16Shahejan Shaikh 16
@tony2009, Did you get any solution for this problem? How can we populate recordtypeIds as per destination Org in automated script?
Mario BurgosMario Burgos
In salesforce data import, for the insert a record type, i can use 
RecordType:RecordType:Name in Headboard
 and button column NameRecordType