# Upsert record action
The Upsert record action searches a data table for an entry matching the primary key you specify. If a matching record is found, the action updates it with the values you specify. If a matching record is not found, the action creates a new record with the values you specified.
# Input
Input fields | Description |
---|---|
Data table | Select the data table in which you plan to upsert a record. Click the link in this field's description to view the selected data table in the data tables interface. |
Primary key | Select the column to use as a primary key. The action uses the Record fields value of this column to find the record to update. If no record matches the given Record fields value of this column, the action instead creates a new record with the Record fields values. |
Choose the desired output format | Optional. Specify how to map the upserted record data to the table fields. Refer to the Output formats section for more information. |
ADDITIONAL INPUT FIELDS
The Record fields section contains an input field for each column of the selected data table. Use these input fields to specify the values to upsert the record with. If you leave a field empty, Workato does not update the corresponding column.
These input fields are subject the same restrictions as their corresponding columns, for example:
- If a column is required, its corresponding field is also required.
- The value you provide must match the corresponding column's data type. For instance, text columns only accept alphanumeric characters. Refer to Column types for detailed information on the accepted values for each data type.
# Output
Output fields | Description |
---|---|
Record created | A boolean (true or false ) value indicating whether a new record was created. |
Record | Contains information about the modified record, such as its Record ID , Created at date, Updated at timestamp, and data from any of the data table's custom columns. |
Last updated: 2/13/2025, 9:08:00 PM