Change constraint: patient-med_card_fk
Fix small bugs.