re:Data modeling issues for a travel planning system

From: kevin <kevin.pang_at_gmail-dot-com.no-spam.invalid>
Date: Fri, 04 Nov 2005 02:10:01 -0600
Message-ID: <vuKdnTEHTNnEivbeRVn_vQ_at_giganews.com>



I didn't consider your logic very carefully, quick suggestions:
  • Use an integer as the primary key for each table. Integer is more efficient and much easier to maintain. The integer can be auto increment, or use a table to maintain last used ID.
    • One PK in one table.

The tables will look like:
STATION:
- (PK) ID (interger)

LINE:
- (PK) ID (integer)

STATION_LINE:
- (PK) ID (integer)

  • line_id
  • statname (station name)
  • direction_id
  • nextstat_id

ATTRACTION:
- (PK) ID (integer)

Hope this helps. Received on Fri Nov 04 2005 - 09:10:01 CET

Original text of this message