Database Structure?
This WebDNA talk-list message is from 1998
It keeps the original formatting.
numero = 19261
interpreted = N
texte = I'm posting this message again 'cause I think the answers I was looking forgot lost in my over-long explanation of the problem.My question was how do you know when to create one database with manyfields OR several databases with a few fields each. I read Peter Ostry'ssomewhat helpful post Re: autocommit problem, BUT I'm not sure which oneapplies to my situation. I'll try to explain what my client wants and maybesomeone with some more experience can point me in the right direction.(It's my first time, be gentle)Client has a database of approx. 6,000 dive gear itemss in a variety ofbrands and categories (masks, fins, snorkels, BC's, books, wet-suits, etc.)Client wants a user interface that goes like this: Visitor hits Entry.tpland is presented with two pull-down menus Search by brand & Search byCategory. If Client chooses say, Masks from the Search by Categorypull-down menu, it will take them to the Search.tpl where they can furthernarrow the search by checking boxes of mask brands they're interested in,weather they have a preference for 2 windows or 4 windows, what kind ofpurge system they'd prefer, and what colors they'd like. After submitting the form, they'd be taken to the Results.tpl that willlist all the products that meet the visitor's criteria (sorted by titlesince the client doesn't want ten of the same product listed just becausethe SKU is different for each color availability and/or size). Then, avisitor could click, details on one of the products listed to go to theDetails.tpl. Here, the visitor will of course see the product image,description, etc. From this page the visitor should be able to choose whatsize & color the want and add the item of their choice to their shoppingcart. Okay, that seems normal but here's the catch. In othercategories, or even worse, if the visitor choose to search by brandinitially, the fields may need to be entirely different. For example, Ifthey choose the brand Blue Reef from the Entry.tpl pull-down menu, thenon the Search.tpl It would list all the categories of products that BlueReef makes and each item would have a pull-down menu to take the user tothe Blue Reef product subcategory they choose. Let's say the choose go tothe pull-down menu under Dive Computers, and choose the sub-categoryMetric. (You can see already that my Search.tpl will be TOTALLY differentdepending on weather or not they click Search by brand or Search byCategory.) So now the user get to the results page & sees a list of allthe Blue Reef, Metric, Dive Computers (again sorted by title) and theycan click on the details link to see more info but NOW instead of showingthe # of windows, size, and color info, they are shown weather or not theproduct is PC download-able, or Nitrox, Hoseless or Air Integrated. [GULP!]As a newbie to WebCatalog, I'm thinking okay, I'll be using a @$%!-load of[showif] commands on my Search, Results, & Details .tpl's. Then I read apost to the list that says using lots of [SHOWIF 1=2][redirecthttp://www.somepage.com/][/SHOWIF] will slow my server WAY, WAY down. Soshould I instead make a different database for every category? If so how doI search by brand across all categories?The database I created initial contains the following 24 fields:SKU, TITLE, PRICE, WEIGHT, BRAND, CATAGORY, TYPE1, TYPE2, TYPE3, SIZE,SIZECHART, COLOR, SEX, TEMPRANGE, HASIMAGE, IMAGE, HASLIMAGE, LIMAGE,DESCRIPTION, FEATURES, REPLITEM1, REPLITEM2, OPPADD1, OPPADD2, While every record has info in the SKU, Title, Price, & Weight fields, I'vealso included 3 subcategory fields (Type 1, 2, & 3), a field fortemperature range (since that is something the client wants searchers tobe able to specify when looking for wet suits) a field for color (to beused on items where alt. colors are available), 2 replacement itemsfields (since some item are to be shown on the Detail.tpl as needingadditional batteries, bulbs, etc.), & 2 Optional Additional fields because*sometimes* the client wants to suggest related products if a particularitem is added to their cart.Again, I know I've asked WAY TOO MANY questions in one post but I'mafraid the answers are all inter-dependant. Please forgive me!! To simplify& recap:1. Can I do it all with the one database? & if so:2. Do I have enough (or the right) fields to do all the different searchesI need?3. Is it possible to use *that many* [showif] tags without ridiculousslow-downs?4. If it *would* be better to do multiple databases, say one for eachbrand, how do I do a search calling up all the catagories listed in all thedatabases?I hope that one of you will be able to make sense of this long message andfind it in your busy schedules to give me some advice?100 lbs of thankfulness in advance,Angel J. Bennett ! We want the world and VP / Creative Dir. ! we want it... The WWW Store ! NOW!818-905-6787 ! http://www.thewwwstore.com
Associated Messages, from the most recent to the oldest:
I'm posting this message again 'cause I think the answers I was looking forgot lost in my over-long explanation of the problem.My question was how do you know when to create one database with manyfields OR several databases with a few fields each. I read Peter Ostry'ssomewhat helpful post Re: autocommit problem, BUT I'm not sure which oneapplies to my situation. I'll try to explain what my client wants and maybesomeone with some more experience can point me in the right direction.(It's my first time, be gentle)Client has a database of approx. 6,000 dive gear itemss in a variety ofbrands and categories (masks, fins, snorkels, BC's, books, wet-suits, etc.)Client wants a user interface that goes like this: Visitor hits Entry.tpland is presented with two pull-down menus Search by brand & Search byCategory. If Client chooses say, Masks from the Search by Categorypull-down menu, it will take them to the Search.tpl where they can furthernarrow the search by checking boxes of mask brands they're interested in,weather they have a preference for 2 windows or 4 windows, what kind ofpurge system they'd prefer, and what colors they'd like. After submitting the form, they'd be taken to the Results.tpl that willlist all the products that meet the visitor's criteria (sorted by titlesince the client doesn't want ten of the same product listed just becausethe SKU is different for each color availability and/or size). Then, avisitor could click, details on one of the products listed to go to theDetails.tpl. Here, the visitor will of course see the product image,description, etc. From this page the visitor should be able to choose whatsize & color the want and add the item of their choice to their shoppingcart. Okay, that seems normal but here's the catch. In othercategories, or even worse, if the visitor choose to search by brandinitially, the fields may need to be entirely different. For example, Ifthey choose the brand Blue Reef from the Entry.tpl pull-down menu, thenon the Search.tpl It would list all the categories of products that BlueReef makes and each item would have a pull-down menu to take the user tothe Blue Reef product subcategory they choose. Let's say the choose go tothe pull-down menu under Dive Computers, and choose the sub-categoryMetric. (You can see already that my Search.tpl will be TOTALLY differentdepending on weather or not they click Search by brand or Search byCategory.) So now the user get to the results page & sees a list of allthe Blue Reef, Metric, Dive Computers (again sorted by title) and theycan click on the details link to see more info but NOW instead of showingthe # of windows, size, and color info, they are shown weather or not theproduct is PC download-able, or Nitrox, Hoseless or Air Integrated. [GULP!]As a newbie to WebCatalog, I'm thinking okay, I'll be using a @$%!-load of
[showif] commands on my Search, Results, & Details .tpl's. Then I read apost to the list that says using lots of [SHOWIF 1=2][redirecthttp://www.somepage.com/][/SHOWIF] will slow my server WAY, WAY down. Soshould I instead make a different database for every category? If so how doI search by brand across all categories?The database I created initial contains the following 24 fields:SKU, TITLE, PRICE, WEIGHT, BRAND, CATAGORY, TYPE1, TYPE2, TYPE3, SIZE,SIZECHART, COLOR, SEX, TEMPRANGE, HASIMAGE, IMAGE, HASLIMAGE, LIMAGE,DESCRIPTION, FEATURES, REPLITEM1, REPLITEM2, OPPADD1, OPPADD2, While every record has info in the SKU, Title, Price, & Weight fields, I'vealso included 3 subcategory fields (Type 1, 2, & 3), a field fortemperature range (since that is something the client wants searchers tobe able to specify when looking for wet suits) a field for color (to beused on items where alt. colors are available), 2 replacement itemsfields (since some item are to be shown on the Detail.tpl as needingadditional batteries, bulbs, etc.), & 2 Optional Additional fields because*sometimes* the client wants to suggest related products if a particularitem is added to their cart.Again, I know I've asked WAY TOO MANY questions in one post but I'mafraid the answers are all inter-dependant. Please forgive me!! To simplify& recap:1. Can I do it all with the one database? & if so:2. Do I have enough (or the right) fields to do all the different searchesI need?3. Is it possible to use *that many*
[showif] tags without ridiculousslow-downs?4. If it *would* be better to do multiple databases, say one for eachbrand, how do I do a search calling up all the catagories listed in all thedatabases?I hope that one of you will be able to make sense of this long message andfind it in your busy schedules to give me some advice?100 lbs of thankfulness in advance,Angel J. Bennett ! We want the world and VP / Creative Dir. ! we want it... The WWW Store ! NOW!818-905-6787 ! http://www.thewwwstore.com
Angel Bennett
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
PSC recommends what date format yr 2000??? (1997)
Large databases in WebCat (1997)
Separate SSL Server (1997)
Webcatalog and foreign languages (1998)
Help! WebCat2 bug (Ben's input) (1997)
suggestion (1997)
Netscape 3.01 can't see db in form (1997)
form data submission gets truncated (1997)
Re:emailer 150 (1997)
still having shipCost.db Problem (1997)
I can help! (1996)
Access to shopping cart files (2005)
can WC render sites out? (1997)
Client-side Image Maps and WebCat? (1998)
Need relative path explanation (1997)
[format xs] freeze (1997)
Listserver problem (1997)
[WebDNA] drop off not round off (2011)
[WebDNA] Image resizing on the fly (2012)
Hiding HTML and page breaks (1997)