close ad
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues


Planning a Database for E-Cart / E-Commerce

Thread began 5/21/2009 3:50 pm by vela1606379889 | Last modified 6/29/2009 10:51 am by anonymous | 4694 views | 6 replies |


Planning a Database for E-Cart / E-Commerce

Hello All,

I'm entering data into my database at present to prepare to have my site make a move to be capable to buy online. The data will be pulled to a table and I will use Ecart. I was hoping I could get some feedback on the best way to setup the database, according to e-cart's capabilities/workings so I won't have to do it twice or enter unnecessary items.

My questions:

1. If I have an Item, say "T-Shirt", and have multiple sizes and colors for that item, do I need to enter all the possible combinations of those into my database? IE

Item Size Color Price
T-Shirt S Red $10.00
T-Shirt M Red $10.00
T-Shirt S Blue $10.00

In my case, there are a lot of variables (I would have 400 items for one "item" if I separate them.

What I was hoping for was to simply enter;

Item Price
T-Shirt $10.00

And then have a drop down box with e-cart. E-cart would allow the user to select size and color and then somehow output this in the invoice/receipt so that the shipping people would know what size and color they wanted.

Also, what if say a large t-shirt costs more, can E-cart determine that somehow or can I set that up in E-cart? Or should all items of different price have their own unique item in the database?

How would you enter this type of data based on your knowledge of e-cart? Individual items in every possible combination? One item? Items with the same price as one item?

Best Regards,

Sign in to reply to this post

Ray BorduinWebAssist

There are still a lot of options for what you could, might, and should do in your database. All are compatible with eCart, so that shouldn't be your focus.

Your focus should be how to best represent your data in your database. The best database design for your specific application is the best database design to use with eCart.

Are you doing inventory control? If you are they probably have to be listed as individual items in the database anyway so that you can track inventory on them individually. If not, you can probably organize them into a database structure that better suits your needs.

Additional price for larger items again is accomplished any number of ways. If you have individual items, then it is easy to see how you would accomodate individual prices.

If you are using a different database design with a single product and related options tables, then you can store an additional price with an option and integrate that into eCart as well. If the information can be retrieved from the database, then it can be used by eCart.

Sign in to reply to this post
Did this help? Tips are appreciated...


GREAT! Thanks Ray, we will make individual items so that we can control inventory later with the database and figure out the e-cart portion when we are ready in a week or so. Thanks for the help.

Sign in to reply to this post

Ray BorduinWebAssist

The hardest part will be creating a simple and intuative administrative section.

The second hardest part will be creating a simple catalog to display the correct information you want organized how you want it.

The easiest part will be integration into eCart once people can find and select what they want from your catelog.

Sign in to reply to this post
Did this help? Tips are appreciated...




I keep bumping into this as I ponder my own project. I don't know how the big guys do this. Is a SKU typically unique to each product size? Like say Macy's has a bunch of men's shirts. Does each size carry it's own SKU?

It seems like the easiest approach is a hybid (and they get great gas mileage too, lol). From a front end perspective it almost has to be separate tables. It seems rather daunting to pull from a single table yet offer all color and size options as drop downs. On the other hand the ONLY way to manage inventory is the single table. The inventory table could be sparse. In other words not every combination would be listed only those with stocking inventory. If a previously unstocked combination was purchased the SKU could be formed by concatenating the product and price options. Like a men's dress white shirt in 3XL might be MDWH3XL.

I don't know, just typing out loud. What do you think of a hybrid approach? Can you see any issues? Is it just a bunch more work or might this help?

Sign in to reply to this post

Ray BorduinWebAssist

I ponder the same question late at night sometimes... We are adding options into the powerstore in the next release.

It will use separate products in the products table for each possible option combination... this way you can have separate inventory, sku, description, or whetever else you want on an product by product basis.

We add a checkbox to the update page to "update all options" in the case that they want a single SKU across multiple combinations they can quickly update the description, size, sku, or inventory of all of the items individually.

It ended up requiring some pretty complex querying and functionality to pull off on the back end and make easy to use at the same time as providing the functionality needed.

The hybrid approach may be good as you suggest but it would add complexity on something that is already pretty complex. I don't want to say it is a bad idea, since I have pondered how to create a store that works well for inventoried items but doesn't have all the complexity for uninventoried and a hybrid approach may be necessary in the long run to accommodate everyone's needs.

Sign in to reply to this post
Did this help? Tips are appreciated...


Ok, I did it over the weekend. The product inventory table is the central table with relationships to the options. So if you think of it like shirts (I'm not at liberty to say what the product is.) I have like 10 different shirt styles which are in essence options, and there are 15 different sizes, which again are options. There are many more options which may eventually be added but at present this is all. The inventory table is sparse, in that it doesn't have a record for anything not in stock. So if the record returns empty then the product can't be ordered. The weight is mostly related to size but there are some variations based on the shirt so the shipping weight is contained in the inventory table as well as the SKU and price all of which can then be unique. It actually wasn't that bad. I still have the flexibility selections list for options because the options are now just straight forward tables with one row for each option. The inventory table just has keys to the options. The inventory table has a quantity on hand which gets debited with purchases.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question





Ease of use


security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...