Database Design - Relationsships
Date: 19 Sep 2002 23:04:48 -0700
TimeLog Customers Projects --------- -------- -----
*TimeLogID *CustomerID *ProjectID
CustomerID ProjectNo ProjectID CustomerID
You can enter a record in the timelog table without having a project e.g. an employee may do a job for a customer that does not have any project numbers.
I want to make sure if the user picks a project it is a project that has the same customerid as the entered customerid in other words: a Time log entry should not be able to have one customerid and a project with another customerid. I know how to prevent this in the GUI but I want to prevent it in the database design.
How should these tables be structured?
/Patrik Received on Fri Sep 20 2002 - 08:04:48 CEST