Welcome Guest, Not a member yet? Register   Sign In
active record's transaction and Models
#1

[eluser]akkumaru[/eluser]
it seems that i cannot use the database class’ transaction like this:

Code:
$this->load->model("model1","",TRUE);
$this->load->model("model2","",TRUE);

$this->db->trans_start();

$this->model1->update($value1);
$this->model2->update($value2);

$this->db->trans_complete();

first update will not be rolled back even when the second is failed..
how to solve this?
#2

[eluser]akkumaru[/eluser]
can it be solved




Theme © iAndrew 2016 - Forum software by © MyBB