View Single Post
Old 01-28-2008, 04:04 PM   #2 (permalink)
Alan @ CIT
Member of the Month
The Frequenter
Member of the Month Top Contributor 
 
Alan @ CIT's Avatar
 
Join Date: Apr 2005
Location: South UK
Posts: 483
Thanks: 51
Alan @ CIT is on a distinguished road
Default

I would probably go for option 2 with an additional index-type table. This index table would have 3 columns.

Column 1: id - this would be a unique id for each item
Column 2: item_type - types of item - ie, the table name the details are stored in (weapon, engine, etc)
Column 3: item_uid - this would corospond with the item id in it's table.

So essentially a cross between options 2 and 3. However, no-one has ever confused me with a database design expert so I'm sure one of my fellow TalkPHPers will arrive shortly to give you a better way

Alan
Send a message via MSN to Alan @ CIT
Alan @ CIT is offline  
Reply With Quote
The Following User Says Thank You to Alan @ CIT For This Useful Post:
DeMo (01-29-2008)