public function DatabaseConnection::inTransaction in Drupal 7
Determines if there is an active transaction open.
Return value
TRUE if we're currently in a transaction, FALSE otherwise.
6 calls to DatabaseConnection::inTransaction()
- DatabaseConnection::pushTransaction in includes/
database/ database.inc - Increases the depth of transaction nesting.
- DatabaseConnection::rollback in includes/
database/ database.inc - Rolls back the transaction entirely or to a named savepoint.
- DatabaseConnection_mysql::rollback in includes/
database/ mysql/ database.inc - Rolls back the transaction entirely or to a named savepoint.
- DatabaseConnection_sqlite::popTransaction in includes/
database/ sqlite/ database.inc - Decreases the depth of transaction nesting.
- DatabaseConnection_sqlite::pushTransaction in includes/
database/ sqlite/ database.inc - Increases the depth of transaction nesting.
File
- includes/
database/ database.inc, line 1063 - Core systems for the database layer.
Class
- DatabaseConnection
- Base Database API class.
Code
public function inTransaction() {
return $this
->transactionDepth() > 0;
}