Closed markdanese closed 7 years ago
The alternative is to add drug_exposure_details and measurement_details ids to the clinical codes table. This would be more of a "fact table" approach.
Per Marc, yet another option is to have foreign keys in both tables so that queries are efficient in either direction. This is only a tiny step from actually pulling the details tables back into their partner tables, which is something that might be better in column store databases anyway.
We decided to add drug_exposure_detail_id and measurement_detail_id to the clinical_codes table and keep admission_detail_id in collections table.
this would require us to put a collections_id in the admission_details table and would be more consistent with how measurements and drug exposure are handled