Patient Home clinic

Patient Sync (deprecated)

This is ZEPRS-specific information.

When a patient is registered in the system, site_id is set in the patient table. This never changes unless explicitly changed in demographics. The site_id is usually the site id of the site that the pc is configured for in "Setup."

Someone from another site may edit a patient record. This is useful when the patient moves to another clinic, the patient is referred to UTH, or when someone makes a correction to a patient record from another site. The site_id field in another table - patient_status, which holds data that often changes for the patient - is changed. If the user is adding a new encounter, the created_site_id and site_id is set in yet another table - encounter - and patient_status.site_id is updated. If the user is editing a record, encounter.site_id and patient_status.site_id is updated.

For the caching to work optimally, a patient must "belong" to a single clinic. When a site is "offline," the expectation from the system will be that a patient record will be updated in only two places:

  • the patient's "home" clinic - the clinic the patient belongs to
  • UTH, in case the patient was referred to another clinic while the site is offline.