File data transfer examples.


Table of Contents



Example 1. Migration of Feed Attachments along with Feed Item or Feed Comment.

Below is example of import (Insert) chatter attachments with chatter feed items using the core:ExportFiles Add-On module.

The SFDMU will automatically detect and maintain relationship between the parent records and attachments.

{
    "objects": [
        {
            "operation": "Readonly",
            "query": "SELECT Id FROM Account WHERE Name = 'ACC_10000'",
            "externalId": "Name"			
        },
        {
            "operation": "Insert",
            "query": "SELECT Id, Body, ParentId$Account FROM FeedItem WHERE Type = 'ContentPost'",
            "afterAddons" : [
                {
                    "module": "core:ExportFiles"
                }
            ]
        }
    ]
}

References:

core:ExportFiles module

Last updated on 14th Apr 2024