0

I want to apply transactions but only for this request.is it any impact on insert , update on other table by other users at same.

$conn = ConnectionManager::get('default');
 $conn->begin();
try{
   //code here
    $conn->commit()
}catch(\Exception){
    $conn->rollback()
}
unset($conn);
Basant Rules
  • 785
  • 11
  • 8
  • It's really hard to tell what you're asking for, you may want to rephrase your question. – ndm Jun 02 '17 at 12:06
  • how to apply roll back in cakephp 3.1, is there is any drawback ? – Basant Rules Jun 02 '17 at 12:34
  • That's a totally different question now, and it's also not very clear. From your example you know how to apply a rollback. And what drawbacks are you potentially afraid of? What is the context of all this? – ndm Jun 02 '17 at 13:17

0 Answers0