mds1256 Posted April 18, 2014 Share Posted April 18, 2014 Hi Looking to implement this ER Diagram but not entirely sure how I would implement the relationship between the Parking and the AuthorisedCars entity. Basically the Parking entity will record the parking event in that it will record the reg number, the time and date of the event as well as if the car left or entered the car park. The Reg number along with the Time and date are down as the primary key. In the AuthorisedCar entity has the Reg number along with the make, model and colour of the car and this will be used to record all the authorised cars that are allowed to park. The relationship shows that a Parking event may or may not be for an Authorised Car, and that an Authorised Car may or may not have Many Car Parking Events. How would I represent this relationship in a Relational Model for the database implementation. I thought of a foreign key for Reg Number in the Parking entity as a car that is NOT on the authorised list may enter / exit the car park so a foreign key is not acceptable as there will not be a matching entry in the AuthorisedCar entity. How would you implement this? Thanks Quote Link to comment https://forums.phpfreaks.com/topic/287878-how-to-represent-this-relationship-on-this-erd/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.