public function rollback()
{
if ($this->_transactionLevel === 0) {
throw new DbException('There is no active transaction');
}
$this->_transactionLevel--;
if ($this->_transactionLevel === 0) {
$this->fireEvent('db:rollbackTransaction');
if (!$this->_pdo->rollBack()) {
throw new DbException('rollBack failed.');
}
}
}