Page 1 of 1

Shopping Cart Scenario. Soloution Needed.

Posted: Wed Jan 26, 2005 10:33 am
by mmc01ms
Just a question regarding a certian scenario that could and most likely would occur in my website im developing for a project.

Customer A is shopping around my site adding items to their cart. They buy a vinyl which there is only one item avaible. Customer B visits the page for that vinyl which still displays only 1 left because customer A has still not gone through a checkout process so the item has not been deducted from the stock level. They buy the vinyl straight away and then the item is deducted from the stock level.

Now Customer A goes to the checkout and makes the order and the item is deducted from the stock-level again or they can't buy that item cause there is not enough.

My question is what would be a logical soloution to this and how you would handle this. One idea i though of is when the customer adds an item to their cart i use a query to minus that from the stock level straight away but not sure how i could do this. any help guys?

Posted: Wed Jan 26, 2005 10:53 am
by feyd
when items go out of stock, they would have already been ordered again to keep them in-stock, however it will happen from time to time, or with rare vinyls in your case.

You can set up a back-order system instead. Where instead of deducting when they order, it's deducted when the item is shipped. This way your system can notify them that the order may take a while, due to shortage. Allowing them to cancel the order is helpful.