         ON (f.primary_entity_id = people.entity_id)
 ;
 
+ALTER TABLE dw_morbidity_patients
+    ADD CONSTRAINT dw_morbidity_patients_pkey PRIMARY KEY (id);
+CREATE INDEX dw_morbidity_patients_entity_ix ON dw_morbidity_patients (entity_id);
+CREATE INDEX dw_morbidity_patients_birth_gender_ix
+    ON dw_morbidity_patients (birth_gender);
+CREATE INDEX dw_morbidity_patients_ethnicity_ix ON dw_morbidity_patients (ethnicity);
+CREATE INDEX dw_morbidity_patients_birth_date_ix
+    ON dw_morbidity_patients (birth_date);
+CREATE INDEX dw_morbidity_patients_date_of_death_ix
+    ON dw_morbidity_patients (date_of_death);
+
 CREATE TABLE dw_contact_patients AS
 SELECT
     people.id,

    e.type = 'MorbidityEvent'
;

CREATE TABLE dw_contact_answers AS
SELECT
    a.*


ALTER TABLE dw_patients_races
    ADD CONSTRAINT pk_dw_patients_races PRIMARY KEY (id);
CREATE INDEX dw_patients_races_patient_id ON dw_patients_races (person_id);
CREATE INDEX dw_patients_races_race_ix ON dw_patients_races (race);

CREATE TABLE dw_events_treatments AS
SELECT
