We have a scheduled flow which we do not want to be invoked in the sandbox.
Is it possible in any way to prevent that ?
- manual option would be to just 'Deactivate' the flow
- like soql: SELECT IsSandbox FROM Organization LIMIT 1 ??
Manual option indeed would be to deactivate the flow in the sandbox.
Automated solution :
Add a getRecord element in the flow to query Organization
object and choose to fetch only the first record.
Then use a decision element that reads the variable returned by getRecord and if isSandbox
field equals to false, then proceed with the rest of the flow logic. This option means that the flow won't execute in any Sandbox