Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 382775
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T15:13:06+00:00 2026-05-12T15:13:06+00:00

I am building an e-commerce website from scratch and have to make a special

  • 0

I am building an e-commerce website from scratch and have to make a special product configuration page.

It’s only 1 type of product, but it is configurable on several levels:

  1. Color (about 4 different options). Value is a VARCHAR.
  2. Material (about 10 different options). Value is a VARCHAR.
  3. Size (About 30 different options). Has 2 Values, a width column and a height column.
  4. Finish (About 20 different options). Value is a VARCHAR.
  5. Other various VARCHAR options etc.

My question is what would this look like in a typical MySQL database. Do I have a table for each type of option or just one table and somehow give it enough columns and have it store all options? I will need to store orders and be able to store the information for the order in a table as well.

I also want to be able to have off the shelf products that aren’t customizeable, just like a normal store.

Any help is appreciated!!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T15:13:07+00:00Added an answer on May 12, 2026 at 3:13 pm

    I suggest that you go with one master table, with all of the product information, and a slew of lookup tables, that connects to the master table.

    It should look like this:

    Product_table:
       ID primary key,
       ColorInt int foreign key lkp_Color_table.ID,
       Material_int foreign key lkp_Material_table.ID,
       // snip the rest
    

    And here’s the lookup table:

    lkp_color_table:
       ID primary key,
       ColorStr varchar,
       description varchar
    
    lkp_Material_table:
       ID primary key,
       MaterialStr varchar,
       description varchar
    

    The Product_table can look like this:

    ID||ColorInt||Material
    1 ||1       ||1
    2 ||1       ||2
    

    Whereas the lkp_color_table can look like this:

    ID||colorstr||description
    1 ||red     ||red color
    2 ||blue    ||blue color 
    

    Note that lkp_color_table can contain unused color , same goes for other lookup tables. So if you have 30 possible colors, you just have to populate lkp_color_table with 30 items, and so on.

    There is no need to create a separate Product_id for each color-material- combination, you just have to create a product_id if you use it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm building an e-commerce website. I have a Product and Order models. It's possible
I'm building an e-commerce website in ASP.Net/C# and I'm having some difficulties with my
I'm building an e-commerce website with a large database of products. Of course, is
Building my solution succeeds, but the build fails upon copying from the build to
Building a website. When I order my tags like this, LightCycle works but Lightbox
I am implementing an e-commerce website using django. The product catalog will be big
Building a solution from Visual Studio in mono develop seems to have some issues.
Suppose we are building an E-commerce site that allows consumers to search for products
noob question: I'm building a checkout system for an online commerce site. I'm getting
Am currently evaluating the best RIA technologies to use for building a new e-commerce

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.