Add MCU participant daily refresh SP
This commit is contained in:
@@ -569,6 +569,24 @@ class Preregisterv3 extends MY_Controller
|
||||
$this->sys_error("update mcu_preregister_patients : ".$last_qry);
|
||||
exit;
|
||||
}
|
||||
$qry_sync_patient = $this->db->query(
|
||||
"CALL cpone.sp_upsert_mcu_patient_by_preregister_id(?)",
|
||||
array($last_id_x)
|
||||
);
|
||||
if (!$qry_sync_patient) {
|
||||
$last_qry = $this->db->last_query();
|
||||
$this->db->trans_rollback();
|
||||
$this->sys_error("call sp_upsert_mcu_patient_by_preregister_id : " . $last_qry);
|
||||
exit;
|
||||
}
|
||||
if (isset($this->db->conn_id) && $this->db->conn_id instanceof mysqli) {
|
||||
while ($this->db->conn_id->more_results() && $this->db->conn_id->next_result()) {
|
||||
$dummyResult = $this->db->conn_id->store_result();
|
||||
if ($dummyResult instanceof mysqli_result) {
|
||||
$dummyResult->free();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user