D365 Finance & Operations and Dynamics AX Forum

D365FO How To: Manage Unit Prices with > 2 Decimals

By Kaare Boraas posted Oct 24, 2019 03:24 PM

  

On most Dynamics 365 for Finance and Operations projects, there is confusion around how to deal with unit prices where the decimal precision is greater than 2 (e.g. fuel $1.1638 per L). Many projects go down the road of customization to achieve this, but there is a standard feature intended for this purpose.  It allows any level of decimal precision.

There is a field called "Price Unit" that indicates how many units the unit price relates to. By default, the price unit is 1, but it can be changed in the master record for the item or directly on a PO, SO, invoice, etc. If you want to enter a unit price for fuel of $1.1638 per L you would actually need to enter a unit price of $116.38 and a per unit of 100. So the cost is $116.38 for 100 L (i.e. $1.1638 per L). The same as how gas stations display their prices.  When the system calculates the total cost, it will use the extra decimal precision and then round the total correctly to 2 decimals. So if you buy 10L you would pay $11.64.

Don't forget that you will have to update the output forms like the PO and SO to accommodate this. For example, you can't send a PO to a vendor with a unit price is $116.38 without including that it is for 100 units. You will either have to add the price unit field to the output or calculate the unit price for one unit ($116.38 divided by 100) and include it on the form.

 

3 comments
24 views

Permalink

Comments

28 days ago

Since I have done this modification more times than I can count, it is far easier to modify the 1/2 dozen things instead of the possible 10's to 100's of things in AX that don't show the price unit in combination with the price. It is much more confusing than anything, and should have been fixed a long time ago. For this reason, every project i am on the solution architect tries with price unit, but then we end up modifying. 

I grabbed a purchase order line off the internet, don't have access right now to an env. But this is the problem, you see the price, but no price unit. And every other report in AX is almost the same, and users start complaining immediately, as they have no idea if it is price per 1, 10, 1000 etc. 

The financial reports are a different value, they aren't the unitprice EDT, so they just show 2 decimals, or whatever the local settings are set for on the client.

28 days ago

Hello @Michael Franchino.  Thanks for your reply.  I don't disagree with you.  It's a pretty common requirement and the native "price unit" feature is hard for people to wrap their heads around.  Once they get it, it works pretty well.  I like that you can set a default by item so it isn't all or nothing.  Some items can have a default of 4 or more decimals while other items stick with 2 decimals.  As for modifying the output documents like POs, it's pretty common to adjust those anyway but I agree it is extra work and maintenance.  The other option is to extend the decimal precision via customization.  That can get tricky.  You only want to touch the unit price field so you don't end up with 4 decimals on your financial statements.  You'll need to do a bunch of extra testing.  In particular pay attention to rounding.

28 days ago

As you said in your last paragraph, you will have to MODIFY a ton of external documents as well as many AX/D365 forms/lists to show the price unit, which doesn't show. This is the main reason why not one of my customer in the past 18 years allowed for us to implement price unit.

Why AX/D365 doesn't allow the expansion of this field is beyond me. Especially coming from many legacy ERP systems that allow for 8 decimals.