swoole_mysql->rollback

回滚事务。

function swoole_mysql->rollback(callable $callback);
  • 必须先调用begin启动事务才能调用rollback否则底层会抛出Swoole\MySQL\Exception异常
  • 异常code22