Referencing Old (Pre-edit) Values in a Workflow

A workflow can change the values of a record when the workflow runs. When you create conditions for workflow initiation, actions, or transitions, you can reference the values of the record that existed in the database at the point where the user started saving the changed record. The old record is obtained before the first Before Submit workflow is executed and is used for both Before Submit and After Submit workflows.

The Condition Builder in the Workflow Manager contains the Record dropdown list. Use this dropdown list to choose other records that can be joined with the current record. You can also use this dropdown list to select the Old Record option. Use this value to reference fields on the Field dropdown list from the current record in the workflow, before the record entered the workflow.

A screenshot showing "Old Record" being selected in the Record column.

Old Record Guidelines

Use the following guidelines when using pre-edit values for a record.

Example of Reacting to a Change in a Field

A common use case for referencing old values in a workflow is reacting to a change in a field on a record. In this situation, you would create a condition similar to Old Record.Some Field != Some Field.

Consider a workflow on a task record that has a Pending Approval state. In this state, you can send an email to the task record assignee when the Priority state is set to High. To do this, you create a Send Email action with a condition for the Priority field.

To create the example Send Email action:

  1. Click the Pending Action state in the workflow diagrammer.

  2. Click New Action in the Context Panel.

  3. Click Send Email.

  4. Set the following properties for the action:

    • Trigger On: After Record Submit

    • Use the Condition Builder (Visual Builder) to set the following condition for the Priority field: Old Record : Priority (Task/Call) != Priority (Task/Call) And Priority (Task/Call) = High

    • Sender:

      • Specific Sender: checked

      • Sender: Specify a sender

    • Recipient:

      • From Field: checked

      • Record (Join Field): Current Record

      • Field: Assigned

    • Content:

      • Custom: checked

      • Subject: Your task has been escalated!

      • Body: Your task ‘{title}’ has been escalated to High priority!

  5. Click Save.

Note:

The formula for the condition built with the condition builder represented by a formula is {old.priority.id} = 'HIGH'.

Related Topics

Condition Examples
Defining Conditions for Customer Credit Hold Field
Workflow Conditions
Working with Conditions

General Notices