In order to migrate attachments from Salesforce to Dynamics 365, we could use Kingswaysoft without writing any code through the Developer version.
Kingswaysoft has a premium Derived column tool available that decodes the Attachment encoded string from Salesforce.com and migrates it to Dynamics 365. The license needs to be obtained only to use the SSIS package in production as a scheduled job or through the command line tool.
The process is explained as below:
- Download the Kingswaysoft Productivity tools here.
- Once it is installed, reopen the Visual studio and the Premium tools should appear in the SSIS toolbox as below.
- Drag and drop the Premium Derived Column to the DataFlow.
- Use the DecodeBase64 function and use the field where the attachment is stored. In the below case, it is the field Body from Salesforce.com.
- Make sure the DataType is DT_Image, which will be automatically populated.
- Run the SSIS package after mapping the column with the documentbody field in Annotation entity in Dynamics 365.
- Verify by opening the document/pdf from the associated entity (example case or opportunity or quote). The PDF will open in CRM with the same contents as in Salesforce.com.
Voila! You’ve migrated your Salesforce.com attachments Dynamics 365!
Happy Dynamics 365’ing!