Database Design
-
I am developing an ecommerce website, aimed at selling electronic products. So for storing the product details I use a product table in which I have the fields for storing the product specifications. My problem is how to include the specifications of different products like motherboard, mouse, Monitor in a single table (product table). How should I design the product table to hold the specifications of different products. Suggest me a good database design for this problem.
-
I am developing an ecommerce website, aimed at selling electronic products. So for storing the product details I use a product table in which I have the fields for storing the product specifications. My problem is how to include the specifications of different products like motherboard, mouse, Monitor in a single table (product table). How should I design the product table to hold the specifications of different products. Suggest me a good database design for this problem.
I don't recommend you save the specifcations in the same table as your products. This is a classic one to many relationship which should be implemented in two tables; it will be so much easier in the long run. For example: Product table PROD_ID Description other fields Specificaitons Spec_ID Prod_ID Description my 2 cents :cool: