Calculations

DDIC

Registered User.
Local time
Today, 00:16
Joined
Jul 30, 2002
Messages
11
Howdy People,


I have a general question about doing some calculations.
I have a form an on that form I have two fields one is a quantity
field and the other is a total cut lenght field. i would like to take the total cut lenght and multiply it to the quanity field, and the answer I get from that take that amount out of my materials in stock field on my table. Leaving me with a new total in the material in stock field. How would go about doing that, a query or
write a macro. Any suggestions would help out.


thanks a bunch,
DDIC
 
Well, if you wanted to do this the excruciatingly correct way, you would not alter the amount in stock in your inventory table because that isn't where it would be...

In theory, an inventory is the sum of all "RESTOCK" and "ISSUE" transactions. (And "SHRINKAGE" if that applies.) You would write a single table that contained every "RESTOCK" event (with date/time stamp) and every "ISSUE" event (with date/time stamp). Obviously, the initial amount in your inventory is manually entered as a "fake" RESTOCK event.

The transactions usually are written so that a RESTOCK is an add and an ISSUE or a SHRINKAGE is a subtract. There are many ways to skin this cat.

If that layout is set up, then the amount on hand at any time is simply the sum of all transactions for the item in question, with each transaction's sign being applied as appropriate.

So to answer your question, the way to do what you asked for IN THE CONTEXT I DESCRIBED would be to create a transaction to ISSUE the appropriate amount of the item.
 
Thanks for the advise The_Doc_Man, I'll look into what you said.

DDIC
 

Users who are viewing this thread

Back
Top Bottom