$this->db->insert('myTable', array(
'title' => 'My title',
'name' => 'My Name 1',
'date' => '1972-12-12 00:00:00'
));
$this->db->insert('myTable', array(
'title' => 'Another title',
'name' => 'Another Name 1',
'date' => '1972-12-12 00:00:00'
));
$data = array(
array(
'title' => 'My title' ,
'name' => 'My Name 2' ,
'date' => '2003-06-28 00:00:00'
),
array(
'title' => 'Another title' ,
'name' => 'Another Name 2' ,
'date' => '2003-06-28'
)
);
$this->db->trans_begin();
$this->db->update_batch('myTable', $data, 'title');
echo $this->db->last_query();
$this->db->trans_rollback();