Hi everyone, I'm new here, so please be patient if my question is trivial, or not very clear.
I have a table tblCC, which stores data about the chief complaint of patients when they go to the physician, as well as details about that complaint (ie. was fever present, did the patient have a cough, etc)
A patient can have more than one chief complaint per visit, so tblCC has a double primary key on the fields [VISITID] and [CCID].
The table tblICD9 contains all the possible complaints a person can have, as well as the type of complaint (respiratory, neurological, cardiovascular, etc). tblICD9 also has a double primary key, on fields [CCID] and [TYPE], because some complaints fall under more than one type.
For example, if the CCID for a stroke is "567", I would have two records
I have a query that is based on both tables, called qryCC. I then have a form based on qryCC for data entry (I am only modifying the data in tblCC).
Here's the thing: some questions are only relevant to certain types of complaints. To make things easier for the interviewer, I want to be able to enable the relevant details fields for the type of chief complaint, and disable the others.
I know how to code this for one-to-one relationships, but I don't know how to handle the fact that a [CCID] is linked to more than one [TYPE].
A) Is my table structure correct for what I am trying to do (particularly the structure of tblICD9)
B) How do I enable/disable certain fields based on the [CCID]'s corresponding [TYPE]s, considering that some have only one record in tblICD9, but that others have many?
I have a table tblCC, which stores data about the chief complaint of patients when they go to the physician, as well as details about that complaint (ie. was fever present, did the patient have a cough, etc)
A patient can have more than one chief complaint per visit, so tblCC has a double primary key on the fields [VISITID] and [CCID].
The table tblICD9 contains all the possible complaints a person can have, as well as the type of complaint (respiratory, neurological, cardiovascular, etc). tblICD9 also has a double primary key, on fields [CCID] and [TYPE], because some complaints fall under more than one type.
For example, if the CCID for a stroke is "567", I would have two records
Code:
[CCID] [TYPE]
567 NEUROLOGICAL
567 VASCULAR
I have a query that is based on both tables, called qryCC. I then have a form based on qryCC for data entry (I am only modifying the data in tblCC).
Here's the thing: some questions are only relevant to certain types of complaints. To make things easier for the interviewer, I want to be able to enable the relevant details fields for the type of chief complaint, and disable the others.
I know how to code this for one-to-one relationships, but I don't know how to handle the fact that a [CCID] is linked to more than one [TYPE].
A) Is my table structure correct for what I am trying to do (particularly the structure of tblICD9)
B) How do I enable/disable certain fields based on the [CCID]'s corresponding [TYPE]s, considering that some have only one record in tblICD9, but that others have many?