Answers for "can we use db transaction under another transaction in laravel"

PHP
0

Db transaction laravel

DB::beginTransaction();

try {
    DB::insert(...);    
    DB::commit();
} catch (\Exception $e) {
    DB::rollback();
    throw $e;
} catch (\Throwable $e) {
    DB::rollback();
    throw $e;
}
Posted by: Guest on July-27-2021

Code answers related to "can we use db transaction under another transaction in laravel"

Browse Popular Code Answers by Language