////
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements.  See the NOTICE file
distributed with this work for additional information
regarding copyright ownership.  The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License.  You may obtain a copy of the License at
  http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied.  See the License for the
specific language governing permissions and limitations
under the License.
////
:documentationPath: /pipeline/transforms/
:language: en_US
:description: The Salesforce Upsert transform updates existing records and inserts new records into your Salesforce database using the Salesforce Web Service.

= image:transforms/icons/SFU.svg[Salesforce Upsert transform Icon, role="image-doc-icon"] Salesforce Upsert

[%noheader,cols="3a,1a", role="table-no-borders" ]
|===
|
== Description

The Salesforce Upsert transform updates existing records and inserts new records into your Salesforce database using the Salesforce Web Service.

You can also use the following other transforms to modify your Salesforce database:

* xref:pipeline/transforms/salesforceinput.adoc[Salesforce Input]: Reads records directly from your Salesforce database.
* xref:pipeline/transforms/salesforceinsert.adoc[Salesforce Insert]: Inserts records directly into your Salesforce database.
* xref:pipeline/transforms/salesforceupdate.adoc[Salesforce Update]: Updates records directly into your Salesforce database.
* xref:pipeline/transforms/salesforcedelete.adoc[Salesforce Delete]: Deletes records directly from your Salesforce database.

|
== Supported Engines
[%noheader,cols="2,1a",frame=none, role="table-supported-engines"]
!===
!Hop Engine! image:check_mark.svg[Supported, 24]
!Spark! image:question_mark.svg[Maybe Supported, 24]
!Flink! image:question_mark.svg[Maybe Supported, 24]
!Dataflow! image:question_mark.svg[Maybe Supported, 24]
!===
|===

== General

Enter the following information in the transform name field:

* Transform name: Specifies the unique name of the Salesforce Upsert transform on the canvas.
You can customize the name or leave it as the default.

include::salesforce-connection.adoc[]

include::salesforce-settings.adoc[]

[options="noheader"]
|===
|Upsert Comparison Field|Specify the Salesforce ID of the field to use as a basis of comparison to determine if you are updating an existing record or inserting a new record.
|===

=== Output Fields

Enter the output information in the following transform option:

Salesforce ID fieldname: Specifies the field to contain the Salesforce ID of the first record in the set of records (batch) you updated and inserted.

include::salesforce-fields.adoc[]