Location: PHPKode > scripts > Persist Class > persist-class/demo6-transactionhandling.php
<?php

// connect to database (executing demo 1)
require('demo1-connection.php');

// get connection object
$con = DbConnectionPool::instance()->getConnection();

$con->startTransaction();
$sql = 'INSERT INTO TESTTABLE(testcolumn) VALUES("INSERTSUCCESS")';
$con->rollBack();
//$con->commit();

echo 'Test successful';

?>
Return current item: Persist Class