Jump to content
yrstruly

Basic Databse Design 1

Recommended Posts

Does Anybody have a SQL code that does the following ones of or is it done in parts?1. DB Schema Design - Design a basic database to store the following information + A fleet of Vehicles - Include details such as mileage, vin numbers etc + A pool of drivers - Include relevant documentation, e.g. Drivesr license, ID Book + A group of routes - Marking out GPS coords for directions etc. is not necessary, just include a start & end address as well as any other info you believe to be pertinent + A drivers schedule, tying the above 3 tables together

Edited by yrstruly

Share this post


Link to post
Share on other sites

sounds like homework.

 

what have you tried so far?

Share this post


Link to post
Share on other sites

If they're asking you to do that, wouldn't they have taught it in class first? Do you have a textbook?

Share this post


Link to post
Share on other sites

I only know of one way to design tables and fields. If you have a database design book then it will cover that stuff.

Share this post


Link to post
Share on other sites

Does Anybody have a SQL code that does the following ones of or is it done in parts?

 

Are you saying you have a database assignment but you don't know anything about databases? How does that happen?

Share this post


Link to post
Share on other sites

I don't know if it is a repeating schedule or a mix of repeating and non-repeating routes.

 

Tables:Vehicles PK is VIN (int)Drivers PK is DID (int)Routes PK is RouteNo (int)For a mix of repeating and non-repeating...

 

Schedule table:SID int (PK)day-of-week char(3)repeats booleandate date departure timeRouteNo int (FK)DID int (FK)VIN int (FK)

 

For a strictly repeating schedule...

 

Schedule table:day-of-week char(3) (PK)RouteNo int (FK) (PK)

departure time (PK)DID int (FK)VIN int (FK)

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...