In Salesforce flows, having a proper and consistent naming convention is important. It helps with readability, understanding, and logic processing.

When working with a single record, it makes sense for the variable to be singular. Similarly, when working with multiple records in a collection, it makes sense for the variable to be plural.

This means if you’re getting, updating, creating, or deleting a single account record, calling the variable `Account` is clear.

Similarly, when doing a DML operation for a collection, calling the variable `Accounts` is also clear.

In addition, sometimes you need to update an account in one part of the flow and create an account in another part. Rather than call these variables `Account1` and `Account2`, a more descriptive name can be used. For example, `AccountToUpdate` and `AccountToCreate`.

The takeaway
As long as you maintain a strong naming standard, it’s obvious to any reader what the variable contains. And that helps future consultants understand how your flow works.

Category:
Salesforce