sf_get_job_records_bulk {salesforcer} | R Documentation |
Returning the Details of a Bulk API Job
Description
This function returns detailed (row-level) information on a job which has already been submitted completed (successfully or not).
Usage
sf_get_job_records_bulk(
job_id,
api_type = c("Bulk 1.0", "Bulk 2.0"),
record_types = c("successfulResults", "failedResults", "unprocessedRecords"),
combine_record_types = TRUE,
verbose = FALSE
)
Arguments
job_id |
|
api_type |
|
record_types |
|
combine_record_types |
|
verbose |
|
Value
A tbl_df
or list
of tbl_df
, formatted by Salesforce,
with information containing the success or failure or certain rows in a submitted job
Note
With Bulk 2.0 the order of records in the response is not guaranteed to match the ordering of records in the original job data.
References
https://developer.salesforce.com/docs/atlas.en-us.api_asynch.meta/api_asynch
Examples
## Not run:
job_info <- sf_create_job_bulk('insert', 'Account')
input_data <- tibble(Name=c("Test Account 1", "Test Account 2"))
batches_result <- sf_create_batches_bulk(job_info$id, input_data)
# pause a few seconds for operation to finish. Wait longer if job is not complete.
Sys.sleep(3)
# check status using - sf_get_job_bulk(job_info$id)
job_record_details <- sf_get_job_records_bulk(job_id=job_info$id)
## End(Not run)