I'm working on a constituent relationship management system in Microsoft Access 2007. We have two types of contributors each with their own tables:
The table Constituents, which has individual people with names and ages and a bunch of foreign keys to different contact information in different tables
The table Organizations, which has fields about org-specific info.
Both Constituents and Organizations can make multiple contributions, which are represented by records in one of 3 tables Pledges, InKindDonations, and MonetaryContributions. These 3 tables can't be merged, they hold different types of info.
Allowing Organizations to make contributions will be a new feature in an existing database. Currently only Constituents can make contributions: each of the 3 contribution tables has a ConstituentId field which is a FK to the [Constituents].[ConstituentId] field.
I am having trouble coming up with a good way to link contributor records from Constituents & Organizations with contribution records while maintaining referential integrity using features available in Access, and making minimal changes to the many existing queries and procedures which reference the 5 tables.
My only idea is that I could add an OrgId field in each of the 3 contribution tables, which would be a FK to Organizations.OrgId -- but I would have to ensure that one and only one of the 2 FK fields ( ConstituentId & OrgId) exists for each contribution, and that they are valid FKs.
Is this a good solution or an ugly hack?