Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Table design

Status
Not open for further replies.

discusmania

IS-IT--Management
Oct 24, 2000
158
AP
hi guys....
is there anywhere i can fine guide on how to design a good db table ?

thanks for the help
 
Usually designing a table is fairly straight forward. It's the relationships between tables that can get tricky. You need to be able to think like an application designer (given this piece of information, can I get from here to there), while at the same time doing low-level database tasks.

One tip:
Use an auto-increment field to provide uniqueness and for updating records (pick a record from a list, save the ID for when you later update it after editing the record). But use a "Code" or "Name" field for your primary key and for linking tables. The reasoning behind this is if you ever have to copy rows from one database to another, the auto-increment fields will never line up, but if all your relationships and keys are based on your code field, then they're OK.

Chip H.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top