patient_allergies table
The patient_allergies table in the Hospital Management System Database Schema schema has 7 columns, keyed by id, with 3 foreign keys to patients, allergens and staff.
Read by the pharmacy module before any prescription is written.
Columns (7)
| Column | Type | Constraints | Description |
|---|---|---|---|
| id | uuid | primary key | |
| patient_id | uuid | not null, references patients.id | |
| allergen_id | uuid | not null, references allergens.id | |
| severity | severity | not null | |
| reaction | varchar(255) | ||
| recorded_at | timestamptz | not null | |
| recorded_by_staff_id | uuid | references staff.id |
Indexes (1)
(patient_id, allergen_id)unique
Relationships
patient_allergies.patient_idreferencespatients.idpatient_allergies.allergen_idreferencesallergens.idpatient_allergies.recorded_by_staff_idreferencesstaff.id