sf_update {salesforcer} | R Documentation |
Update Records
Description
Updates one or more records to your organization’s data.
Usage
sf_update(
input_data,
object_name,
api_type = c("SOAP", "REST", "Bulk 1.0", "Bulk 2.0"),
guess_types = TRUE,
control = list(...),
...,
all_or_none = deprecated(),
verbose = FALSE
)
Arguments
input_data |
|
object_name |
|
api_type |
|
guess_types |
|
control |
|
... |
arguments passed to |
all_or_none |
|
verbose |
|
Value
tbl_df
of records with success indicator
Note
Because the SOAP and REST calls chunk data into batches of 200 records the AllOrNoneHeader will only apply to the success or failure of every batch of records and not all records submitted to the function.
Examples
## Not run:
n <- 2
new_contacts <- tibble(FirstName = rep("Test", n),
LastName = paste0("Contact", 1:n))
new_records <- sf_create(new_contacts, "Contact")
updated_contacts <- tibble(FirstName = rep("TestTest", n),
LastName = paste0("Contact", 1:n),
Id = new_records$id)
# update and allow fields to be truncated if they are too long
update <- sf_update(input_data = updated_contacts, object_name = "Contact",
AllowFieldTruncationHeader=list(allowFieldTruncation=TRUE))
## End(Not run)