1
0
mirror of synced 2024-12-13 22:56:04 +03:00
doctrine2/manual/codes/Database operations - Nested transactions.php

18 lines
311 B
PHP
Raw Normal View History

2006-07-24 01:08:06 +04:00
<?php
try {
$session->beginTransaction();
$user->save();
$session->beginTransaction();
$group->save();
$email->save();
$session->commit();
$session->commit();
} catch(Exception $e) {
$session->rollback();
}
?>