p782115798 发表于 2018-1-8 15:40:11

事务调试模式使用插入数据id自增问题

在执行事务调试模式时候
数据会回滚,但是自增id会自增
$this->db->trans_start(TRUE);
$this->db->insert('table',$data);
$this->db->trans_complete();
if ($this->db->trans_status() === FALSE)
{

}else{

}

mysql 引擎 :InnoDB
页: [1]
查看完整版本: 事务调试模式使用插入数据id自增问题