Database design question

Hi,



I am currently working on my college project which is a bus timetable database in MYSQL. However, I am inexperienced in database design and am having problems.



I have the following entities



BUS, ROUTE, STOP, RUN, EXTRA_INFO



A bus must follow one route only. A route must consist of many stops. A stop may be used by many routes. A run may be subject to additional_info (eg not Sunday). A bus makes many runs each day. A bus may travel to or from town.



The database must be able to answer the following querie....



"What bus do I need to get from X lane to Y lane. I would like to travel on or after 10:00."



Another problem is that I'm not sure how the database will cope if X lane is after Y lane in the query. ie the user wants to travel away from town instead of into town.



Any advice or pointers to useful sites would be very-much appreciated.



Thanks, Catrina


Comments



  • : "What bus do I need to get from X lane to Y lane. I would like to travel on or after 10:00."



    what you have described is the exact problem all the travel sites are having. They are currently running fancy interfaces on the same code used for the last 20 years. Now if you can devise a better method, you need to start a dot-com of your own.



    Sorry I cannot be of any help, but I thought I would let you know the magnitude of which you spoke.



    Good luck.




  • Roger,



    thankyou for your honest advice. I reluctantly agree that I have bitten off more than I can chew!

    I still intend to use a similar idea but I will have to reduce the functionality.

    I am thinking of changing the service offered to the following...

    "Give me a list of all buses that go from Penny Lane".

    This would return all buses and times they leave from an entered stop. I believe this is a lot more simpler, would you agree?



    Regards,

    Catrina.


  • : Roger,
    :
    : thankyou for your honest advice. I reluctantly agree that I have bitten off more than I can chew!
    : I still intend to use a similar idea but I will have to reduce the functionality.
    : I am thinking of changing the service offered to the following...
    : "Give me a list of all buses that go from Penny Lane".
    : This would return all buses and times they leave from an entered stop. I believe this is a lot more simpler, would you agree?
    :
    : Regards,
    : Catrina.
    :
    :

    Much better...yes

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories