Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

best way to do inventory control

Status
Not open for further replies.

cogswell

Programmer
Nov 23, 2002
1
US
I am building a database with 2 basic databases. One with products and their quantities and one Invoice databse. What is the best way to subtract my invoice quantity from my product quantity safely and reliably? Thanks !!

Adam
 
Hi, Cogswell.
In my opinion, the safest, reliable solution is to use a scripted SET FIELD from the invoice file.
Set Field "Inventory::New Bal", "Inventory::Curr Bal" - "Quantity"
.
.
Set Field "Inventory::Curr Bal", "Inventory::New Bal"
The reason for the gap is that the second script step sets the thing in concrete. Up to then you can cope with changes in the Invoice and also cover 'out of stock' situations.
Alternatively, you could leave it until the user accepts the invoice but then you can't do much in the way of editing without being extremely annoying to the user.
HTH Cheers,
Paul J.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top