Last Direct Cost?

Where do the “Last Direct Cost” for an item come from? It is my understanding that it is created and updated each time that specific item is purchased and invoiced. We use Average cost as our costing method for purchased materials and we are running 3.60. I am curious because I have come across an interesting issue with the “Last Direct Cost” for a large number of items (approx. 60 items), whos prices vary widely from one item to the next. The “Last Direct Cost” for many of them has changed to an identical value for no reason that I can discover, and no manual adjustments have been made to the item cards. I have compared the costs to the corresponding invoices and found that the Unit Cost we have matches, but it is the Last Direct Cost that seems to comes from nowhere. Has anyone else come across anything like this, it seems to me that Navision is just creating random numbers to populate some areas.

Hi, Navision copies the latest direct unit cost from the Direct Unit Cost field in the Purchase Line table when you post an order as invoiced.If you use journals, the program copies the direct unit cost from the Unit Amount field on item journal lines of the Purchase entry type. Might be someone has used Item Journal to post some Purchase Entry.Please check the source of entries.

Hi, Even positive adjustments affect or the Physical Inventory Journal as well.

Two posibilities: *Variuos Unit of Measure Codes *Currency

Thank you, I will have to look at your suggestions and examine those entries more closely. We do use Physical Inventory Journals for monthly inventory adjustments, as we still have differences in inventory amounts from physical counts to Navision amounts. Cheers

I have had this problem reported to me last week. The customer has V3.10A and Average Cost. They recently changed from Average Cost Calc. Type = Item to Item & Location & Variant. Since then they have reported that a number of Items have the wrong Last Direct Cost. Even Items that have had no recent activity. I have tracked this down to Phys. Inventory Journals. Items in the journal with zero Quantiy and Amount that follow a Positive Adjustment for an Item with a positive Quantiy all acquire the Last Direct Cost of the Item adjusted. I am working on the cause of this.

Last Direct Cost is the Unit Purchase Cost before any line discount This is used for showing the Last Direct Cost when a new order is created Also note that LDC is used for positive adjustment and will lead to wrong average cost when doing Phys. Inventory

For eg: Buy @ USD 10 GET 50% Avg / Unit Cost USD 5 Last Direct Cost USD 10/-


We had that same problem. We use 3.10b I’d figured it was fixed by 3.6. Anyway it happened to us while using the Phys Inventory Journal. ex/ If we entered 5 items item1 item2 item3 item4 item5 During The cycle count we noticed item 1 & 5 needed an adjustment. items 2 thru 4 did not. item1 -1 item2 0 item3 0 item4 0 item5 +1 we noticed that after posting items 2,3 & 4 took on the cost of item1. Seems to be due to the fact that there was no change to these items. We had this fixed and you could also filter on zero changed items first & delete them. But that’s an extra step that shouldn’t have to be done. that was our experience.

The following code fix has been provided by MBS with a qualification: Note that the code fix being provided in this communication cannot be considered to be an official hotfix or service pack for the reported issue, and hence the partner takes all responsibility for its implementation and ongoing support as well as future upgrades. Although MBS Services resources have tested it internally, it is strongly recommended that both the partner and the customer in suitable test environments, before being released into a production environment, also test it. After further investigation, this issue has been raised in support request # NZ-796-137-66EK. It is visible in Partnerguide. Codeunit 22 … UpdateUnitCost() WITH GlobalValueEntry DO BEGIN IF (“Valued Quantity” > 0) AND (NOT “Expected Cost”) THEN BEGIN // Any increase in net invoiced quantity or item charge Item.LOCKTABLE; IF NOT Item.FIND THEN EXIT; IF (“Item Ledger Entry Type” IN [ “Item Ledger Entry Type”::Purchase, “Item Ledger Entry Type”::“Positive Adjmt.”, “Item Ledger Entry Type”::Output]) AND (amount + “Discount Amount” > 0) AND (ItemJnlLine.“Value Entry Type” = ItemJnlLine.“Value Entry Type”::“Direct Cost”) AND (ItemJnlLine.“Item Charge No.” = ‘’) AND (“Invoiced Quantity” > 0) THEN BEGIN LastDirectCost := ROUND((ItemJnlLine.Amount + ItemJnlLine.“Discount Amount”) / “Invoiced Quantity”,GLSetup."Unit-Amount Rounding Precision);//Add ROUND((Amount + “Discount Amount”) / “Invoiced Quantity”,GLSetup.“Unit-Amount Rounding Precision”);//Remove I have tested this and it certainly fixed my problem.