Re: Help with inventory control - Mailing list pgsql-general

From Fernando Grijalba
Subject Re: Help with inventory control
Date
Msg-id f817a44d0509301214l4f55e89cic7928040fecd3aa2@mail.gmail.com
Whole thread Raw
In response to Re: Help with inventory control  (Douglas McNaught <doug@mcnaught.org>)
List pgsql-general
Thank you for your input Doug, but that did not work. User2 was still getting the qty unchanged.

Any more ideas?

I was thinking of creating a table that will hold the product code and the qty taken by an order.  check this table evey minute and if a product has been there for more that 10 minutes and return it to inventory if that is the case.  After I save the order I would remove the prodcut for this order from this table.  This way I can just update the qty in one transaction when the user gets the product for the order and then save the order in a different transaction.  This will allow me to reduce the quantity at the time the order obtained the product and increase it when the order is cancelled or if the user forgets or his/her computer crashes.

Is this a good idea?  Your input is appreciated.

Fernando

pgsql-general by date:

Previous
From: Devrim GUNDUZ
Date:
Subject: Re: Redhat 9 RPM dependency problem
Next
From: Mike Nolan
Date:
Subject: Re: Help with inventory control