In Salesforce Flow, errors can occur in a Record-Triggered Flow after you change the API name of a custom field. The errors occur because $Record references in Decision and Assignment elements are not automatically updated to the new API name.
This article describes which elements update automatically and how to manually update the references.
This section explains why a Salesforce Record-Triggered Flow shows errors after you change a custom field API name, and how to fix the references.
In Salesforce Flow, errors may occur in a Record-Triggered Flow when you change the API name of a custom field. This happens because the old API name is not automatically updated when `$Record` or `$Record__Prior` is used in the resource section of Decision or Assignment elements.
The following table shows whether the API name is automatically updated for each element and reference method. This table does not cover all possible scenarios.
| Element / Reference Method | Automatically Updated |
| Decision element | No |
| Assignment element | No |
| Get Records element | Yes |
| Update Records element | Yes |
| Value section (for example, `{!$Record.newfield__c}`) | Yes |
| Reference via Get Records element (for example, `{!Get_Account.newfield__c}`) | Yes |
If you use `$Record` or similar references in Decision or Assignment elements, you must manually update them to the new API name. Follow these steps to update the field references:
Creating a new version or simply deactivating and reactivating the flow does not resolve the issue. You must manually correct the references.
005460862

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.