Flow input currency variable is not handled properly in Multi-Currency org
Last updated 2022-02-10 ·Reference W-3751066 ·Reported By 2 users
Summary
Consider an auto launched flow with an input currency variable being used in a decision element with a numerical comparison operation against a static currency value - something like {!inputCurrencyArg} < 400
Repro
Go to setup page, Create→ Workflows & approvals→ Flows
Click New Flow to open the cloud flow designer
Create a Decision element
Name: checkCurrencyVal
Create an outcome
Name: true
Resource: Create a new input variable of type Currency called inputCurrency
Make the criteria as {!inputCurrency} < 400Create a record update element
Name: updateObject
Object to be updated: Account
Filter by: Name contains test
Field to update: Description
Value to update: Updated from flow
Make the Decision element as the starting element.
Connect the two elements and save the flow with name “testFlow” and type “AutoLaunchedFlow”
Now activate the flow.
Creating a process
Go to setup page, Create→ Workflows & approvals→Process builder
Click new
Process Name: testProc
Process starts when: A record changes
+Object: Account
+Criteria
name: true
Choose: No criteria—just execute the actions!
+Immediate Action
Action name: callFlow
flow: testFlow
input variables: inputCurrency:Reference:[Account].AnnualRevenue
Click save and activate the process
Create an account
name: test1
Account revenue: 10
save
It can be seen that the flow executed without any problem and the account description is updated as per the flow record update.
Enabling multi-currency for an org
Follow the following steps to enable multi currency in your local build org - https://sites.google.com/a/salesforce.com/cce/home/debugging-salesforce/enable-multicurrency
After enabling the multi currency for the org, create a new account named test2 or edit the same account and the operation fails with the following error
ERROR: - The record couldn’t be saved because it failed to trigger a flow. A flow trigger failed to execute the flow with version ID 3018E00000079xL. Flow error messages: <b>An unhandled fault has occurred in this flow</b><br>An unhandled fault has occurred while processing the flow. Please contact your system administrator for more information. Contact your administrator for help.
The error email also points to the invocable Flow failure and the stack trace ID Salesforce Error ID: 1463552941292248 (1176380937) - It has no more details in the root cause of the flow failure.
Workaround
Not available
Reported By (2)
Is it Fixed?
Any unreleased services, features, statuses, or dates referenced in this or other public statements are not currently available and may not be delivered on time or at all. Customers who purchase our services should make their purchase decisions based upon features that are currently available.