We have negative stock quantities in inventory. Can this be prevented by configuration? If not, does anybody have any solutions or workarounds to prvent negative inventory being created?
Ive seen posts advising to sort the problem out using journals, we want to prevent it happening in the first place.
:-k
0
Comments
Navison creates Item Ledgers entries for every item posting, and the inventory you see is simply the sum of these entries. There is no inventory stored anywhere in the database, the "Amount" field in the item ledger entries is summed up using the SIFT Technology when the record is displayed on the form.
Why after locking? Because if you do it before and 2 sessions are posting a negative entry on the same item, it is possible that when the the test is done, it is OK for both, but afterwards, the stock will be negative. Eg. you have a stock of 10 items and 2 sessions want to post a negative entry of 8 items. Independant of each other it is possible because the remaining stock will be 2, but if BOTH are posted, there is a problem:you will have a stock of -6! If you do it AFTER locking the table, the second session waits before testing the stock and the problem will not occur.
You have to write some testing code (if "Entry Type"::"Negative Adjmt.", "Quantity" will be positive anyway), you have to check the location code, bin code (if used), serial no, lot no.
...OR to make programming a bit easier : You can write the test AFTER the posting has been done. In that case you don't have to test the "Entry Type", just test on the item no, location code, bin code, serial code, lot no. Put those filters on a T32:"Item Ledger Entry"-record and do a CALCSUMS(Quantity) and give an error if the result is negative. The negative of this is that if it gives an error, you blocked the table to post it for nothing while you could have avoided the blocking time. If negative stock don't happen a lot, this is not a problem.
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
The "Stockout Warning" field in Sales & Receivables Setup can be used to display a warning when a sale will result in negative inventory.