Update Record Action

Estimated reading: 3 minutes 5 views

The Update Record action allows you to update an existing record in the Salesforce database. This action is essential for modifying data dynamically during a process, including ownership changes, status updates, and other field modifications.

Update record action detail

Key Features

  • Updates specific fields in an existing record.
  • Supports dynamic ownership reassignment with flexible owner types.
  • Allows additional input parameters for custom updates.

Configuring an Update Record Action

When adding an Update Record action, the following fields must be configured:


1. Common Properties

  • Label:
    • A user-friendly name for the action, displayed in the process flow.
    • Required field.
  • Name:
    • A unique identifier for the action, used internally.
    • Required field.

2. Inputs

The inputs section defines the parameters required to update the record. The following fields are available:

Required Fields

  1. Record ID:
    • Specifies the unique ID of the record to be updated.
    • Example: {recordId}.

Optional Fields

  1. Owner Type:
    • Determines the ownership of the record being updated.
    • Options:
      • Default: No ownership changes.
      • Process Owner: Assigns the process owner as the record owner.
      • Process Record Owner: Assigns the owner of the associated process record.
      • Running User: Assigns the user executing the process as the record owner.
      • User Field: Assigns ownership based on a specified user field (requires the Owner User input).
      • Static User: Assigns a specific, static user as the record owner based on a specified user field (requires the Owner User input).
      • Queue: Assigns the record to a queue, based on a specified user field (requires the Owner Queue input)

Additional Inputs

  • These inputs allow you to specify additional fields and their new values for the record being updated:
    • Name: API name of the field with fields. at the beggining (e.g., fields.Status, fields.BillingCity, fields.CustomField__c).
    • Type: Data type of the field (e.g., String, Number, Boolean).
    • Value: New value to set for the field.

Example:

Field Name Type Value Comment
fields.Status String Completed Updates the status field to “Completed”.
fields.BillingCity String San Francisco Updates the billing city field.
fields.CustomField__c Boolean true Updates a custom boolean field to true.

Usage Example

Scenario: Updating an Account’s Status and Ownership

  1. Record ID: recordId.
  2. Owner Type: Static User.
  3. Additional Inputs:
    • fields.Status: Active.
    • fields.BillingCity: New York.

Steps:

  1. Add an Update Record action to the process.
  2. Fill in the Label and Name fields.
  3. Specify the Record ID of the account to update.
  4. Set Owner Type to Static User and specify the new owner in the static user configuration.
  5. Add additional inputs to update fields like fields.Status and fields.BillingCity.
  6. Save the configuration and test the process.

Best Practices

  • Ensure that the specified record exists before attempting to update it.
  • Use the Owner Type field carefully to avoid accidental ownership changes.
  • Test the action in a sandbox environment to validate the update logic.
  • Use meaningful labels and input names for better readability and maintenance.

Leave a Comment

       
Euphoria, forever till the end of times

Euphoria

Share this Doc

Update Record Action

Or copy link

CONTENTS