I would like to know what happen when I have some Scheduled Action for version 1 of Process Builder A and I make some changes in the same Process Builder and activate version 2.
The other option is to Deactivate it and then create a new process, however, if you do this.
After you deactivate a process, the scheduled actions continue as usual. If a deactivated process has pending scheduled actions and the record whose field the schedule is based on is changed, Salesforce recalculates the schedule for those actions.
You should probably go through Considerations for Scheduling Process Actions and update your post with your specific use case along any inconsistent behavior or the part in the documentation you don't understand based on your use case.
I've answered this question here. You can read it for the TL DR; version
- If your organization has matured/unchanging SLA's defined, then Move your Time-Based process nodes into a separate process chain so that they dont get cloned everytime you make changes/introduce new immediate action nodes -OR-
- Remove the time-based process nodes and replace with individual time-based workflows instead since they dont have the versioning issue.
I interpret the question to mean: what happens when an individual record is in
Paused Flow Interview state, and a new version of the PB is published?
The record will wake up at its scheduled time and complete its steps according to the version that was active when the timer started.
Full details of my test: https://www.stupidcrmtricks.com/2020/08/what-happens-to-inflight-process.html
Process Builder executes only active version and ignore previous inactive versions. Though all the versions will be saved for historical tracking purposes.
Only one version can be active at a time.
If there are any actions performed by previous scheduled action and it is pending to be executed then still that will in the queue. When you activate new version, any changes to the record will take the latest version.
Refer Automate Business Process with Process Builder Trailhead
Consider the following when creating automated processes.
- You can reorder criteria nodes—just drag and drop them. However, you can’t change the order of actions. After you add actions, the only way to reorder them is to delete them and start over.
- If you create processes to replace any workflow rules, make sure you delete or deactivate those workflow rules when you activate the equivalent processes. Otherwise, both workflow rules and processes fire and cause unexpected results, such as overwritten records or redundant email messages.
- You can add scheduled actions only if the process starts when a record is created, or if the process starts when a record is created or edited and you select Yes when asked “Do you want to execute the actions only when specified changes are made to the record?”
- A process can have up to 50 versions, but only one version of a process can be active.