Solved

Ecommerce database structure

Posted on 2007-11-28
4
1,294 Views
Last Modified: 2008-09-13
I am building an online gift shop and need help deciding how to relate the shopping cart table to the orders table without alitteration.
Customers are not required to log in in order to add items to the shopping baske, but are required to log in or create an account in order to checkout.
here is the information:

ORDERS
-----------
orderid
customerid
orderitems
subtotal
shipmethod
shipcosts
ordertotal
orderdate
ordertrackingNo

SHOPPINGCART
------------------
cartid
customerid
product
quantity

Any suggestions on improvement would be greatly appreciated.

Thanks in advance
0
Comment
Question by:dotinfiniti
4 Comments
 
LVL 22

Accepted Solution

by:
dportas earned 125 total points
ID: 20369401
>> dotinfiniti: I am building an online gift shop
Obvious question: Why? There is an enormous number of pre-packaged solutions available to meet most requirements.

If you want to do this properly then I suggest you seek out the services of an experienced database designer. It's impossible for us to know your requirements just based on two lists of attributes.
0
 
LVL 18

Assisted Solution

by:Jinesh Kamdar
Jinesh Kamdar earned 125 total points
ID: 20372434
I think the logical thing would be store the basket items in the SHOPPINGCART table until the user selects to check-out (not sure how to and if u want to keep the cart persistent thru multiple sessions). Once the user logs in and finalises the order, move the items to the ORDERS and ORDERLINES tables, which would hold the order details and delete them from the SHOPPINGCART table.
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you’re thinking to yourself “That description sounds a lot like two people doing the work that one could accomplish,” you’re not alone.
Many companies are looking to get out of the datacenter business and to services like Microsoft Azure to provide Infrastructure as a Service (IaaS) solutions for legacy client server workloads, rather than continuing to make capital investments in h…
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question