Skip to content

Instantly share code, notes, and snippets.

@nmenda
Created May 6, 2013 20:11
Show Gist options
  • Save nmenda/5527788 to your computer and use it in GitHub Desktop.
Save nmenda/5527788 to your computer and use it in GitHub Desktop.
try {
$schema->txn_do($coderef);
if (!$opt_t) { print "Transaction succeeded! Commiting stocks and their properties! \n\n"; }
} catch {
# Transaction failed
die "An error occured! Rolling back and reseting database sequences!" . $_ . "\n";
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment