Worker can have only one vehicle and Vehicle can belong to only one worker at a time.
There are 3 possible implementations I know:
1.
Vehicle(Id, Number)
Worker(Id, Name, VehicleId)
--> This allows two workers have the same vehicle.
2.
Worker(Id, Name)
Vehicle(Id, Number, WorkerId)
--> This allows worker to have two vehicles.
3.
Worker(Id, Name)
Vehicle(Id, Number)
WorkersVehicles(Id, VehicleId, WorkerId)
--> This allows each worker to have many vehicles and each vehicle to belong to many workers.
None of the above can describe the desired 1:1 relationship.
How can I describe this 1:1 relationship in the DB and in the Entity Framework?