What you have is a classic one to many relationship. In standared MySQL, relationships are not enforced by the database.
1) Use your (unique) primary_key as your foreign keys. i.e.. ad client_id to projects. MySQL will enforce a unique index and not let you add duplicate records.
2) If you merge two client accounts, all you have to do is update the client_id of the affected project records.
|