JohnHarkins
MIS
I've been over this a thousand times in my own mind, but I can't quite get it straight. It's got to be simple, doesn't it?
I want to validate project phases for each item in a master record (tblMaster); for example, project phases can assume several values such as "startup", "design", "test", "implementation", and "retired".
Seems simple enough. Just have those five phases as acceptable values through a validation rule. Good enough.
If I expand from five to six and I have the data in a back-end database, then I have to change the back-end table definition to include the new phase.
But, if I want to add greater flexibility to the application, I want to create a small table in a one-to-many relationship with the master records (one on the tblLookup side and many on the tblMaster side, right?).
However, the database examples I see generated by the wizards create the lookup table with an autonumber unique ID as the primary key. So far so good, but that technique allows the user to add two phases with the same name, I believe. I want to avoid duplicates, don't I? So, why not make the phase name the primary key instead of the autonumber? Doesn't that technique (phase name as primary key) afford me the chance to change the phase name in one place; for example, if instead of the word "design" I now want it to be "imagine" I'd just change the primary key of "design" to "imagine" in tblLookup by using cascading updates.
I probably don't want to have cascading deletes, because that would wipe out master records if I "dropped" a particular project phase, wouldn't it?
Please help clarify my thinking and offer some pro's and con's if you think that would help.
Many thanks,
John Harkins
I want to validate project phases for each item in a master record (tblMaster); for example, project phases can assume several values such as "startup", "design", "test", "implementation", and "retired".
Seems simple enough. Just have those five phases as acceptable values through a validation rule. Good enough.
If I expand from five to six and I have the data in a back-end database, then I have to change the back-end table definition to include the new phase.
But, if I want to add greater flexibility to the application, I want to create a small table in a one-to-many relationship with the master records (one on the tblLookup side and many on the tblMaster side, right?).
However, the database examples I see generated by the wizards create the lookup table with an autonumber unique ID as the primary key. So far so good, but that technique allows the user to add two phases with the same name, I believe. I want to avoid duplicates, don't I? So, why not make the phase name the primary key instead of the autonumber? Doesn't that technique (phase name as primary key) afford me the chance to change the phase name in one place; for example, if instead of the word "design" I now want it to be "imagine" I'd just change the primary key of "design" to "imagine" in tblLookup by using cascading updates.
I probably don't want to have cascading deletes, because that would wipe out master records if I "dropped" a particular project phase, wouldn't it?
Please help clarify my thinking and offer some pro's and con's if you think that would help.
Many thanks,
John Harkins