Using transactions
try {
$dbc->start_trans();
...
$dbc->complete_trans();
} catch (Exception $e) {
$dbc->fail_trans();
$dbc->complete_trans();
throw $e;
}
Executing select
$sql = "select ...";
$rez = $dbc->execute($sql);
if (!$rez->is_eod()) {
$rez_obj = $rez->fetch_object();
}