The document describes a case study for designing a database for a county bus company. The database needs to track buses, routes, towns, stages, drivers, and garages. The entities include buses, routes, towns, stages, drivers, and garages. Buses are allocated to routes, routes pass through towns, stages correspond to parts of routes, drivers are allocated to stages, and buses and towns have garages. The document outlines the relationships between entities and includes an ERD diagram and proposed relational schema to model the database design.
The document describes a case study for designing a database for a county bus company. The database needs to track buses, routes, towns, stages, drivers, and garages. The entities include buses, routes, towns, stages, drivers, and garages. Buses are allocated to routes, routes pass through towns, stages correspond to parts of routes, drivers are allocated to stages, and buses and towns have garages. The document outlines the relationships between entities and includes an ERD diagram and proposed relational schema to model the database design.
The document describes a case study for designing a database for a county bus company. The database needs to track buses, routes, towns, stages, drivers, and garages. The entities include buses, routes, towns, stages, drivers, and garages. Buses are allocated to routes, routes pass through towns, stages correspond to parts of routes, drivers are allocated to stages, and buses and towns have garages. The document outlines the relationships between entities and includes an ERD diagram and proposed relational schema to model the database design.
Case Study Solution Database Design using MySQL 07-Feb-06 : [1]
Entities “A county bus company owns a number of buses and has asked you to create a database to keep track of their business. Each bus is allocated to a particular route, with some routes having several allocated buses. Each route passes through a number of towns. One or more drivers are allocated to each stage of the route, which corresponds to a journey through some or all of the towns on a route. Some of the towns have a garage where buses can be kept, each bus having one ‘home’ garage.”
Case Study Solution Database Design using MySQL 07-Feb-06 : [2]
Relationships ‘Each bus is allocated to a particular route, with some routes having several allocated buses’ BUS [many-to-one] ROUTE ‘Each route passes through a number of towns’ ROUTE [many-to-many] TOWN ‘each stage of the route’ ROUTE [one-to-many] STAGE ‘One or more drivers are allocated to each stage’ DRIVER [many-to-one] STAGE ‘[a stage] corresponds to a journey through some or all of the towns on a route’ STAGE [many-to-many] TOWN ‘Some of the towns have a garage’ TOWN [one-to-one] GARAGE ‘each bus having one ‘home’ garage’ BUS [many-to-one] GARAGE
Case Study Solution Database Design using MySQL 07-Feb-06 : [3]
Case Study Solution Database Design using MySQL 07-Feb-06 : [6]
Review • Practised designing a database from a real life specification: – Define entities, relationships and attributes. – Draw up an EAR diagram. – Map this EAR diagram to a normalised relational table schema.
Case Study Solution Database Design using MySQL 07-Feb-06 : [7]