SchemaSpy Analysis of mimic.mimiciii - Constraints Generated by
SchemaSpy
63 Foreign Key Constraints:
SourceForge.net

Constraint Name Child Column Parent Column Delete Rule
admissions_fk_subject_id admissions.subject_id patients.subject_id Restrict delete 
callout_fk_hadm_id callout.hadm_id admissions.hadm_id Restrict delete 
callout_fk_subject_id callout.subject_id patients.subject_id Restrict delete 
chartevents_fk_cgid chartevents.cgid caregivers.cgid Restrict delete 
chartevents_fk_hadm_id chartevents.hadm_id admissions.hadm_id Restrict delete 
chartevents_fk_icustay_id chartevents.icustay_id icustays.icustay_id Restrict delete 
chartevents_fk_itemid chartevents.itemid d_items.itemid Restrict delete 
chartevents_fk_subject_id chartevents.subject_id patients.subject_id Restrict delete 
cptevents_fk_hadm_id cptevents.hadm_id admissions.hadm_id Restrict delete 
cptevents_fk_subject_id cptevents.subject_id patients.subject_id Restrict delete 
datetimeevents_fk_cgid datetimeevents.cgid caregivers.cgid Restrict delete 
datetimeevents_fk_hadm_id datetimeevents.hadm_id admissions.hadm_id Restrict delete 
datetimeevents_fk_icustay_id datetimeevents.icustay_id icustays.icustay_id Restrict delete 
datetimeevents_fk_itemid datetimeevents.itemid d_items.itemid Restrict delete 
datetimeevents_fk_subject_id datetimeevents.subject_id patients.subject_id Restrict delete 
diagnoses_icd_fk_hadm_id diagnoses_icd.hadm_id admissions.hadm_id Restrict delete 
diagnoses_icd_fk_icd9 diagnoses_icd.icd9_code d_icd_diagnoses.icd9_code Restrict delete 
diagnoses_icd_fk_subject_id diagnoses_icd.subject_id patients.subject_id Restrict delete 
drgcodes_fk_hadm_id drgcodes.hadm_id admissions.hadm_id Restrict delete 
drgcodes_fk_subject_id drgcodes.subject_id patients.subject_id Restrict delete 
icustays_fk_hadm_id icustays.hadm_id admissions.hadm_id Restrict delete 
icustays_fk_subject_id icustays.subject_id patients.subject_id Restrict delete 
inputevents_cv_fk_cgid inputevents_cv.cgid caregivers.cgid Restrict delete 
inputevents_cv_fk_hadm_id inputevents_cv.hadm_id admissions.hadm_id Restrict delete 
inputevents_cv_fk_icustay_id inputevents_cv.icustay_id icustays.icustay_id Restrict delete 
inputevents_cv_fk_subject_id inputevents_cv.subject_id patients.subject_id Restrict delete 
inputevents_mv_fk_cgid inputevents_mv.cgid caregivers.cgid Restrict delete 
inputevents_mv_fk_hadm_id inputevents_mv.hadm_id admissions.hadm_id Restrict delete 
inputevents_mv_fk_icustay_id inputevents_mv.icustay_id icustays.icustay_id Restrict delete 
inputevents_mv_fk_itemid inputevents_mv.itemid d_items.itemid Restrict delete 
inputevents_mv_fk_subject_id inputevents_mv.subject_id patients.subject_id Restrict delete 
labevents_fk_hadm_id labevents.hadm_id admissions.hadm_id Restrict delete 
labevents_fk_itemid labevents.itemid d_labitems.itemid Restrict delete 
labevents_fk_subject_id labevents.subject_id patients.subject_id Restrict delete 
microbiologyevents_fk_ab_itemid microbiologyevents.ab_itemid d_items.itemid Restrict delete 
microbiologyevents_fk_hadm_id microbiologyevents.hadm_id admissions.hadm_id Restrict delete 
microbiologyevents_fk_org_itemid microbiologyevents.org_itemid d_items.itemid Restrict delete 
microbiologyevents_fk_spec_itemid microbiologyevents.spec_itemid d_items.itemid Restrict delete 
microbiologyevents_fk_subject_id microbiologyevents.subject_id patients.subject_id Restrict delete 
noteevents_fk_cgid noteevents.cgid caregivers.cgid Restrict delete 
noteevents_fk_hadm_id noteevents.hadm_id admissions.hadm_id Restrict delete 
noteevents_fk_subject_id noteevents.subject_id patients.subject_id Restrict delete 
outputevents_fk_cgid outputevents.cgid caregivers.cgid Restrict delete 
outputevents_fk_hadm_id outputevents.hadm_id admissions.hadm_id Restrict delete 
outputevents_fk_icustay_id outputevents.icustay_id icustays.icustay_id Restrict delete 
outputevents_fk_itemid outputevents.itemid d_items.itemid Restrict delete 
outputevents_fk_subject_id outputevents.subject_id patients.subject_id Restrict delete 
prescriptions_fk_hadm_id prescriptions.hadm_id admissions.hadm_id Restrict delete 
prescriptions_fk_icustay_id prescriptions.icustay_id icustays.icustay_id Restrict delete 
prescriptions_fk_subject_id prescriptions.subject_id patients.subject_id Restrict delete 
procedureevents_mv_fk_cgid procedureevents_mv.cgid caregivers.cgid Restrict delete 
procedureevents_mv_fk_hadm_id procedureevents_mv.hadm_id admissions.hadm_id Restrict delete 
procedureevents_mv_fk_icustay_id procedureevents_mv.icustay_id icustays.icustay_id Restrict delete 
procedureevents_mv_fk_itemid procedureevents_mv.itemid d_items.itemid Restrict delete 
procedureevents_mv_fk_subject_id procedureevents_mv.subject_id patients.subject_id Restrict delete 
procedures_icd_fk_hadm_id procedures_icd.hadm_id admissions.hadm_id Restrict delete 
procedures_icd_fk_icd9 procedures_icd.icd9_code d_icd_procedures.icd9_code Restrict delete 
procedures_icd_fk_subject_id procedures_icd.subject_id patients.subject_id Restrict delete 
services_fk_hadm_id services.hadm_id admissions.hadm_id Restrict delete 
services_fk_subject_id services.subject_id patients.subject_id Restrict delete 
transfers_fk_hadm_id transfers.hadm_id admissions.hadm_id Restrict delete 
transfers_fk_icustay_id transfers.icustay_id icustays.icustay_id Restrict delete 
transfers_fk_subject_id transfers.subject_id patients.subject_id Restrict delete 

Check Constraints:

Table Constraint Name Constraint
None detected