Precision (UOM, Currency, Price List, Costing)
The purpose of this page is to review and discuss all the places that iDempiere maintains precision.
- Unit of Measure (UOM) window
- Standard Precision - Qty UOM precision
- Costing Precision - Inventory and COGs posting precision
- Currency
- Standard Precision - Amount precsion
- Costing Precision - Inventory and COGs posting precision
- Price List has a precision field that drives the Unit Price precision
Said another way:
The Price List will allow you to set a order's unit price of $1.234567 if the price list precision is high enough. The Currency precision will limit the document's total to $1.23 in the case of USD (precision of 2 by default) and a Qty using "Each" cannot have decimals because the precision is 0.
I have not dug into the code in a while to see which costing precision wins (UOM or Currency) when posting product asset values.
Additional Details
- The Price Entered field will hold as many values as you wish regardless of what precision values you choose (up to a limit ~ 12) when you have not chosen a Product or Charge.
- When you chose a Product or Charge, the price defaults will be constrained by the Price List. This allows for Price List Schema to create high-precision values because of math, but set the Orders with reasonable precision amounts.
- The Line Net Amount field on the sales order is governed by the Currency => Standard Precision.
- Make sure you run Cache Reset and reopen the window before you test your changes each time you make a change.