Update UnitsInStock

jimbo89

Registered User.
Local time
Tomorrow, 07:48
Joined
Jun 7, 2007
Messages
16
Using the Northwind sample database, what is the best way to run an update query that updates the UnitsInStock field based on what has been sold? That is the table is updated based on a particular orderid and only on that orderid. Running an update query at the moment updates the table on all orders and therefore updating the same item several times. I hope I have explained the problem well enough. Can anyone help? Thanks in advance
 
I did some work for a computer hardware refurbisher who adjusted inventory when an order was shipped using the packing list. Their thinking was, if it's still in the building it's in stock and can be shipped to a higher value customer.
 
I've checked Allen's code and it certainly looks like what I want. Where does it actually go ie afterupdate/beforeupdate on a certain form?
Thanks again

Jim
 
You could put it in a standard module and call it whenever you needed it from any form.
 
Glad to help. Post back here if you need further assistance.
 

Users who are viewing this thread

Back
Top Bottom