The database is going to track legal administrative law cases. I've broken
up the data into the following:
tblCaseinfo (currently contains 20 fields)
tblRegion (a many-to-one relationship with tblCaseinfo because each Region
can have multiple cases).
tblRepresentatives (a many-to-one relationship with tblCaseInfo b/c each
representative may have multiple cases)
tblAction (this is the one-to-one relationship with tblCaseinfo since each
case has a specific action, along with date fields relating to when the
action was taken, appealed, etc.)
tblActnDetails (this is a table that contains information about the type of
penalty imposed, amt of penalty, date imposed, etc. This table is a
many-to-one relationship with Action because for every action, there can be a
multitude of penalties)
tblDiscRec - many-to-one with tblCaseinfo
tblDiscSent - many-to-onewith tblCaseinfo
tblHrgs - one-to-one with tblCaseinfo since each case only has one "trial"
(in administrative law they are called "hearings")
tblHrgTasks - many-to-one relationship with tblHrgs
tblIndex - a many-to-one relationship with tblCaseinfo. It is a 3-field
table that logs events for each case.
tblStatus - a one-to-one relationship with tblCaseinfo. Each case only has
one "status" but I split this off because the tblCaseinfo was becoming too
large with too many fields
tblDisposition - one-to-one relationship with tblCaseinfo. Again, each case
only has one disposition, but I split it b/c of size
Here is my dilemma in the design: The first entry of a new case will be in
the tblCaseinfo table. When the user enters the details, he will at that
time also make entries into the tblAction and tblActnDetails tables b/c each
case starts out with that information. But, the case will not necessarily
have information entered about its Status or Hearing (the other one-to-one
relationships with tblCaseinfo) until a later date. I have found that with
the form I have built that if a user begins to enter a new case and gets
interrupted and does not enter information about the Action, than the form
will not display the new record the user began when it is reopened and the
user ends up entering it again, thus creating a duplicate entry. How do I
fix this?
Here is the query for my form the user uses to enter case information:
SELECT tblCaseInfo.*, tblStatus.ClosedDate, tblRegion.ID, tblRegion.SUBOFC,
tblRegion.PM, tblRegion.PMPH, tblRegion.Ext, tblRepresentatives.*,
tblAction.Actn, tblAction.NoticeDate, tblAction.Imposed, tblAction.Appeal,
tblAction.Program, tblAction.Surveys, tblAction.IDROutcome,
tblAction.TotalImposedAmt
FROM tblRepresentatives RIGHT JOIN (((tblCaseInfo LEFT JOIN tblRegion ON
tblCaseInfo.FieldOfc = tblRegion.ID) LEFT JOIN tblStatus ON
tblCaseInfo.CaseId = tblStatus.CaseId) INNER JOIN tblAction ON
tblCaseInfo.CaseId = tblAction.CaseID) ON tblRepresentatives.ID =
tblCaseInfo.RepID;