Get Successful, Failed, and Unprocessed Records Using the Bulk 2.0 Operations

For every bulk operation, the Salesforce application creates a job ID. Once you receive the reference bulk job ID in the final batch response, you can also get the details of the records using the Get Successful Records, Get Failed Records, and Get Unprocessed Records operations for all batch operations available under Bulk v2.0.

This use case provides an overview of how to request all the details of the successful records for the respective job.

This use case uses the following bulk operation:
  • Get Successful Records: Requests all the details of the successful records for the respective job.
Similarly, you can request all the details of the failed or unprocessed records using the following operations:
  • Get Failed Records: Requests all the details of the failed records for the respective job.
  • Get Unprocessed Records: Requests all the details of the unprocessed records for the respective job.
  1. Create an app driven orchestration integration.
  2. Drag the REST Adapter into the integration canvas.
  3. Configure the REST Adapter.
  4. Drag a Salesforce Adapter and configure it with the required bulk operation.
    1. On the Basic Info page, provide a name.
    2. On the Action page, select Perform Bulk Data Operations.
    3. On the Operations page, select Bulk v2.0, and select the required operation (for this example, Get Successful Records) in the Select an Operation field.

      The Operations page for Salesforce shows Cancel and Done buttons at the top. Below is the list of pages that the adapter wizard follows: Basic Info, Actions, Operations, Headers, and Summary. To the right is the > button. Below are the Operations page fields: Bulk v1.0 and Bulk v2.0 radio buttons, the Select an operation list, and the Description field.

    4. Review your selections on the Summary page.
  5. In the mapper of Salesforce Invoke, map the Request 1 to Job Id.

    The mapper shows Request 1 in the Source tree mapped to Job Id in the Target tree. In the middle is the Mapping canvas column.

  6. Drag an FTP Adapter into the integration canvas.
  7. Configure the FTP Adapter as follows:
    1. On the Basic Info page, provide a name.
    2. On the Operations page, select Write File from the Select Operation list.
    3. Select Binary from the Select a Transfer Mode list.
    4. Provide the output directory and file name pattern (.csv).

      The Operations page for FTP shows a Cancel button at the top. Below is the list of pages that the adapter wizard follows: Basic Info, Actions, Operations, Schema, File Contents - Definition, and Summary. Below are the fields Select an operation list, Select a Transfer Mode (selections for ASCII and Binary), Output Directory, File Name Pattern, Append to Existing File, and PGP Encryption / Description.

    5. On the Schema page, select NO.
    6. On the Summary page, review your selections.
  8. In the mapper for the FTP Adapter invoke, map the Dir Path to Job Id.

    The mapper shows Dir Path in the Source tree mapped to Job Id in the Target tree. In the middle is the Mapping canvas column.

  9. In the mapper for the REST Adapter, map the Status to Output1.

    The mapper shows Status in the Source tree mapped to Output1 in the Target tree. In the middle is the Mapping canvas column.

  10. Specify the tracking variable.
    1. Click Business Identifier Business identifiers icon.
    2. Drag the required variable to use for the tracking reference (for this example, Input1 is selected).
  11. Activate the integration.