Jump to content


Normalisation Question

  • Please log in to reply
No replies to this topic

#1 slkhlaw

  • Members
  • Pip
  • Newbie
  • 5 posts

Posted 23 November 2005 - 10:58 AM

I came to a stumble block while trying to design my database. Two problems basically. I hope someone could lend me a hand.

1) I am trying to categorise my stuff into 3 generations of categories (Eg. Main category, Sub category, sub-subcategory). And would like to keep the option open to further sub divide them into 4 generations or more in the future if deemed necessary. My current table looks like this, I don't know how to normalise from here onwards.

Table Item
Item-ID - PK
Location (Cities, Countries, Continents)

What eventually I want to have is a main page which list all the maincategory. When user click to look at a particular main category, all the subcategory will be displayed. And when the user click on the subcategory, all the subsubcategory will be displayed. When the user click further, all the items from the same subsubcategory will be displayed. (A bit like Ebay's category)

2) Second problem also related to the above table.

Location will be dependent on Cities, Countries and Continents. And all the three are related with one another. A bit like subcategory problem above. What basically I want to achieve here is that when a user would like to search by location, i.e. closest cities to him, or the countries he is in. Or within certain continent (i.e. Europe).

Actually I am more comfortable with flat table in this instance, but I can imagine there will be massive amount of duplication. Can someone help me?

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users