May be I do not understand what you want to do, but if you want to see "Inventory" of some item and variant on some specific location, you can use field "Inventory" on the Stockkeeping unit in connection with the "Location filter", or "Inventory" field on Item in connection with "Location Filter" and "Variant Filter".
The Bin makes it much more complex. You need to use table "Bin Content" to SUM the content for the Location/Variant/Item/Bin
Hi,
I have a similar problem.
I have a .NET app that do some export/import of data from webshop to Navision with use of some XMLPORT, CODEUNIT and NAS.
I can see that the most of items has inventory greather then 0 in Navision, but when I check this items in item table (directly in database)so inventory is 0.
where can I get the correct value for inventory and update my CODEUNIT with this value?
May be I do not understand what you want to do, but if you want to see "Inventory" of some item and variant on some specific location, you can use field "Inventory" on the Stockkeeping unit in connection with the "Location filter", or "Inventory" field on Item in connection with "Location Filter" and "Variant Filter".
The Bin makes it much more complex. You need to use table "Bin Content" to SUM the content for the Location/Variant/Item/Bin
Hi, I need to provide an online inquiry/view for my client. So I tried to look at the Item Ledger Entry because that is the link attached to the inventory field on the item card but the Bin field is not there. So Iwas wondering if there is other table that contains the Inventory per location, Variant and Bin.
Hi,
Thanks for your advise.
I did use the following code and for the moment it works fine, I will try yours if I discover that there is some thing wrong.
ThisInventory := 0;
ItemLedgerEntry.SETFILTER(ItemLedgerEntry."Item No.", ItemRecord."No.");
IF ItemLedgerEntry.FIND('-') THEN BEGIN
REPEAT
ThisInventory := ThisInventory + ItemLedgerEntry.Quantity;
UNTIL (ItemLedgerEntry.NEXT = 0);
END;
Comments
The Bin makes it much more complex. You need to use table "Bin Content" to SUM the content for the Location/Variant/Item/Bin
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.
You can also see the Item by Location screen and filter on variant codes.
AP Commerce, Inc. = where I work
Getting Started with Dynamics NAV 2013 Application Development = my book
Implementing Microsoft Dynamics NAV - 3rd Edition = my 2nd book
I have a similar problem.
I have a .NET app that do some export/import of data from webshop to Navision with use of some XMLPORT, CODEUNIT and NAS.
I can see that the most of items has inventory greather then 0 in Navision, but when I check this items in item table (directly in database)so inventory is 0.
where can I get the correct value for inventory and update my CODEUNIT with this value?
Best regards
Nasser
Hi, I need to provide an online inquiry/view for my client. So I tried to look at the Item Ledger Entry because that is the link attached to the inventory field on the item card but the Bin field is not there. So Iwas wondering if there is other table that contains the Inventory per location, Variant and Bin.
Thanks,
You must write Item.CALCFIELDS(Inventory) for the actual item in your Codeunit since Inventory is a flow field with this formula:
Sum("Item Ledger Entry".Quantity WHERE (Item No.=FIELD(No.),Global Dimension 1 Code=FIELD(Global Dimension 1 Filter),Global Dimension 2 Code=FIELD(Global Dimension 2 Filter),Location Code=FIELD(Location Filter),Drop Shipment=FIELD(Drop Shipment Filter),Variant Code=FIELD(Variant Filter),Lot No.=FIELD(Lot No. Filter),Serial No.=FIELD(Serial No. Filter)))
Thanks for your advise.
I did use the following code and for the moment it works fine, I will try yours if I discover that there is some thing wrong.
ThisInventory := 0;
ItemLedgerEntry.SETFILTER(ItemLedgerEntry."Item No.", ItemRecord."No.");
IF ItemLedgerEntry.FIND('-') THEN BEGIN
REPEAT
ThisInventory := ThisInventory + ItemLedgerEntry.Quantity;
UNTIL (ItemLedgerEntry.NEXT = 0);
END;