Re: Design advice needed.
От | Mark Kelly |
---|---|
Тема | Re: Design advice needed. |
Дата | |
Msg-id | 200704042334.26288.pgsql@wastedtimes.net обсуждение исходный текст |
Ответ на | Re: Design advice needed. (Sean Davis <sdavis2@mail.nih.gov>) |
Список | pgsql-novice |
On Wednesday 04 April 2007 23:04, Sean Davis wrote: > Mark Kelly wrote: > > I have been asked to produce a website for selling a very varied range > > of items, around 5000 in all. The client wants to be able to > > categorise items in a hierarchical tree, along the lines of "exhaust > > > round > gold > honda" (it's motorbike parts) but wants to be able to > > use an unspecified number of levels and have that number differ > > between categories. > > The categories are not really hierarchical, are they? A person could > just as easily start with "honda" in the example above as with > "exhaust". Light-bulb appears above head. > I would think instead of making a categories that contains > all the categories. You will need an items table that contains all the > items. Finally, you will want a table that maps items to categories. That's absolutely ideal. I have actually done another database this way in the past (mapping books into genres) but the clients insistence on the hierarchy had kinda locked me into looking at it his way IYSWIM. Thank you. Not only can I proceed happily with this now, I can offer facilities above and beyond what the client is asking for which I always try to do when the spec is informal enough. Thanks again, Mark
В списке pgsql-novice по дате отправления: