Calculating COGS in NAV

Generally COGS (Cost of Goods Sold) is an unknown parameter that must be recorded and calculated. We have (or we can have) exactly information about Beginning Inventory and Net Purchases, but COGS depends of Costing Method:


This is because it is connected with fluctuations over time in the unit acquisition costs of inventory items. COGS will be an unknown value until we choose costing method for each item.

The choice of a costing method has two consequences. It determines which purchase entries and sales entries will be applied to each other when you post a document. This is the application method part of the costing method and I’ve already wrote about it. It also influences the unit cost calculation, which is itself used for posting to the general ledger. This is the cost flow assumption part of the costing method. I’ve already wrote basically about costing methods in Microsoft Dynamics NAV.

And do not forget, regardless of what costing type you use, all of them have minimum one common thing. When the quantity on inventory is zero, the inventory value must also be zero.

Now I want to give you some examples how system uses different costing methods.


When we use FIFO method, system will post quantity decreasing every time based on the first input. If we use LIFO method, situation is totally opposite; quantity decreasing is based on the last input.


When we use average costing method, posting of quantity decreasing however, determined by calculating a weighted average of the remaining inventory at the valuation date of the inventory decrease.


In situation when we use standard costing method, system doesn’t use purchase cost from posted invoices. System will use Standard Cost for all inventory postings (increase and decrease).


And at the end, when we use specific costing method, system is not based on some time order. If we use this costing method, it means we have assumption that individual units of items can be physically identified, typically with serial and/or lot numbers. Every time when we want to post inventory decreasing, we have to choose what exactly inventory unit we want to consume/sale.




Posting Groups #8 – Revaluation Posting

In my last post, I have touched Revaluation process, but only for Standard cost changing. We can use Revaluation for other cases, as well.

If we change cost only for items on stock, it will be the same situation as on previous example. But, if we want to change cost for already sold or consumed stock, it will be with some differences. First, when we change the cost, we will get the same entries, as I already show in previous post. But, when we run Adjust Cost – Item Entries batch job, we will get the new G/L entries.

I made three scenarios:

In the first scenario, I have raw material with FIFO cost type. I consume this raw material on production order to produce finish goods, configured as also FIFO cost type. In this case, result of posting in G/L entry will be as following:


In the second scenario, everything was the same, but only finish goods was configured as Standard cost type. In this case, result of posting in G/L entry will be a bit different, as following example:


And, in the third scenario, I change the cost on already sold items. In this scenario, G/L entries will be as following:


Posting Groups #7 – Change Standard Cost

If you use Standard cost type for your Items and you want to change it, you need to use Standard Cost Worksheet. When you run Implement Standard Cost Changes command, all changes will be moved to Revaluation Journal.

When you post Revaluation Journal, you will get following G/L entries, if you have cost increasing:


If you have cost decreasing, you will get the same Accounts, but the different values, as following: