Error message

You are browsing documentation for drupal 7.x, which is not supported anymore. Read the updated version of this page for drupal 11.x (the latest version).

function DatabaseTransactionTestCase::insertRow

Insert a single row into the testing table.

2 calls to DatabaseTransactionTestCase::insertRow()
DatabaseTransactionTestCase::testTransactionStacking in modules/simpletest/tests/database_test.test
Test transaction stacking and commit / rollback.
DatabaseTransactionTestCase::testTransactionWithDdlStatement in modules/simpletest/tests/database_test.test
Test the compatibility of transactions with DDL statements.

File

modules/simpletest/tests/database_test.test, line 4022

Class

DatabaseTransactionTestCase
Test transaction support, particularly nesting.

Code

protected function insertRow($name) {
 db_insert ('test')->fields (array(
 'name' => $name,
 ))
 ->execute ();
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.