function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Sonya Dhand 3Sonya Dhand 3 

Quanity Must be Non Zero error when custom cloning using a button and flow

Hi

I have created a flow to clone an opportunity and products using a custom button 

The flow clones the original opportunity but the cloned opportunity products are made negative e.e. quantity and total price. 

This works fine if the original qantity is 1 or above howver if the qantiy is 0.5 for example the flow will error with the message

Error Occurred: INSERT --- INSERT FAILED --- ERRORS : (FIELD_INTEGRITY_EXCEPTION) field integrity exception: Quantity (quantity must be nonzero)

I can however change the quantity manually to a minus 0.5 weith no issues but not using a flow.

I tried a formula in the flow to add a minus before the quantiy variable to no avail.

Any ideas?

Mnay thanks

Sonya