Are you looking for an efficient way to handle data uploads in Salesforce? Look no further! The Bulk API Salesforce is here to simplify your data uploading process and provide you with detailed insights. With this guide, you’ll learn how to check the status of your job and retrieve valuable results. Let’s dive in!
Checking the Status of the Job
After you’ve submitted your data and informed Salesforce about the completion of your upload, it’s time to let the server take over and process your request. You have two methods to monitor the server’s progress: using the Salesforce UI or the API.
To check the status of the job in your Trailhead playground, follow these steps:
- From the Setup menu, enter “Bulk Data Load Jobs” in the Quick Find box.
- Select “Bulk Data Load Jobs”.
On this page, you can check the status of your job. Alternatively, you can click on the job ID to get more detailed results.
If you prefer using Postman from the Bulk v2 folder, follow these steps:
- Select “GET Job Info”. Note that the HTTP method used for this request is GET.
- Click “Send”.
You will see a response window, indicating the details of your job and its status.
If your job is still in the UploadComplete state instead of JobComplete, don’t worry! Salesforce is still processing it, and it will be completed within a few minutes. In the meantime, take a break and enjoy a mug of coconut milk. When you return, you can try the same request again. If you’re lucky, your job will be processed, and you can proceed to retrieve the job results.
Retrieving the Job Results
Once your job reaches the JobComplete or Failed state, you can access the results containing information about successfully and unsuccessfully processed records.
To view the successfully processed records in the Bulk v2 folder, follow these steps:
- Click on the “GET Get Job Successful Record Results” resource. Note that the HTTP method is GET.
- Click “Send”.
You will receive a response window showing the names of the accounts returned. Salesforce provides a list of all the records successfully processed in your job. Great job!
In some cases, certain records may encounter errors during processing. It could be due to existing duplicate Account records or missing required fields. To retrieve a list of failed records, follow these steps in the Bulk v2 folder:
- Select the “GET Get Job Failed Record Results” resource. Note that the HTTP method remains GET.
- Click “Send”.
You will receive a response window showing any errors encountered, along with the record ID and error message. If all your records were successfully inserted, the list of records will be empty. Well done, Captain!
For further information and in-depth guidance, refer to the following resources:
- Developer Guide: Bulk API 2.0 Developer Guide
- Developer Guide: Bulk API Developer Guide (an older version of Bulk API not covered in this unit)
Now that you’re equipped with the knowledge of the Bulk API Salesforce, you can streamline your data uploading process effortlessly. Get started today and experience the efficiency and reliability this powerful tool offers. Happy uploading!