Item Master: Item A
Item tracking for lot is selected and at warehouse level as well.
FIFO Method of costing
Inventory Setup:
Automatic cost posting: Yes
Expected Cost posting: Yes
Automatic Cost Adjustment: Always
Average Cost Calc. Type: Item & Location & Variant
Scenario
Step 1: Purchase on 01/07/16 of Item A, qty 10 PCS, unit cost as 1000/- and lot = LOT1, Location = MUMBAI.
Item Ledger Entry:
Cost (Actual) = 10,000/-
Step 2: Purchase on 02/07/16 of Item A, qty 10 PCS, unit cost as 2000/- and lot = LOT1, Location = MUMBAI.
Item Ledger Entry:
Cost (Actual) = 20,000/-
Step 3: Transfer from MUMBAI location to GURGAON location on 05/07/16 of Item A, qty 10 PCS, lot = LOT2.
Item Ledger Entry:
Cost (Actual) = 20,000/-
Step 4: Transfer from MUMBAI location to GURGAON location on 06/07/16 of Item A, qty 10 PCS, lot = LOT2.
Item Ledger Entry:
Cost (Actual) = 10,000/-
Step 5: Selling on 10/07/16 of Item A, qty 5 PCS and lot = LOT1, Location = GURGAON.
Item Ledger Entry:
Cost (Actual) = -5,000/-
Step 6: Selling on 10/07/16 of Item A, qty 4 PCS and lot = LOT2, Location = GURGAON.
Item Ledger Entry:
Cost (Actual) = -8,000/-
In this case FIFO costing is not working but instead it is specific.
Is this correct?.
Thanks,
Darshan
0
Answers
In Codeunit 22, where the application between the item ledger entries takes place, you can find these lines of code which are responsible for this:
IF ItemTrackingCode."Lot Specific Tracking" THEN
ItemLedgEntry2.SETRANGE("Lot No.",ItemLedgEntry."Lot No.");