DB_common::autoCommit()

DB_common::autoCommit() -- Turns auto-commit on or off

Referentiesamenvatting

mixed autoCommit ([boolean $onoff = FALSE])

Beschrijving

Turns auto-commit on or off.

Parameter

boolean $onoff

TRUE to turn auto-commit on. FALSE to turn auto-commit off.

Return waarde

integer - DB_OK on success or a DB_Error object on failure

Throws

Tabel 34-1. Mogelijke PEAR_Error waarden

Error codeError messageReasonSolution
every other error code  Database specific error Check the database related section of PHP-Manual to detect the reason for this error.

Note

Deze functie kan niet statisch worden aangeroepen.

When using MySQL as your DBMS, transactions can only be used when the tables in question use the InnoDB format.

Voorbeeld

Zie

commit(), rollback()