patients table

The patients table in the Hospital Management System Database Schema schema has 11 columns, keyed by id. 9 columns in patient_addresses, emergency_contacts, patient_insurance_policies, patient_allergies and 5 more reference it.

The MRN is the identifier humans use. The uuid is what foreign keys use, so an MRN reissue never breaks history.

Columns (11)

Columns of the patients table
ColumnTypeConstraintsDescription
iduuidprimary key
medical_record_numbervarchar(32)unique, not null
first_namevarchar(80)not null
last_namevarchar(80)not null
date_of_birthdatenot null
sexsex_at_birthnot null
blood_typevarchar(3)
phonevarchar(32)
emailvarchar(255)
deceased_attimestamptz
created_attimestamptznot null

Indexes (1)

  • (last_name, first_name, date_of_birth)

Relationships