If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > Database Structure

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 03-24-10, 20:44
webguy09 webguy09 is offline
Registered User
 
Join Date: May 2009
Posts: 1
Database Structure

Hi all,

I am having a little trouble getting my head round designing some tables as my links seem to be 1 to 1 for the most part.

I am designing a database to store items. The problem arises when it comes to storing unique data about different items, which would require new link to a table. Each item has an ItemID, however the types of items may vary from films, to music, etc. Each has its own attributes. Films would include platform (eg. DVD), music would include platform (eg. Record), etc. However, then a Record would need a table to store its size etc. Here is what I've got so far:

StockTable
ItemID
QuantityInStock
IndividualPrice
ItemTypeID

ItemTypeTable
ItemTypeID
ItemType (eg. Music)
TypeID

MusicTable
TypeID
Type (eg. Record)
RecordID (but what if it's a CD? It would need a MusicID)

RecordTable
RecordID
Size

It is creating that link between the ItemTypeTable, MusicTable, and the RecordTable that is causing me the most grief.

Could anyone help me figure out how to relate these items together in a relational database? Any help is appreciated
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On