laravel-oci8
laravel-oci8 copied to clipboard
ORA-01086: savepoint 'TRANS2' never established
Summary of problem or feature request
I am trying to run the php artisan migrate and I get the following error:
Error Code: 1086
Error Message: ORA-01086: savepoint 'TRANS2' never established
Position: 0
Statement: ROLLBACK TO SAVEPOINT trans2
Bindings: []
System details
- Operating System: Red Hat Enterprise Linux Server release 7.4
- PHP Version: 7.1.13
- Laravel Version: 5.4
- Laravel-OCI8 Version: 5.4
Can you please some snippets to reproduce the issue?
I Had very similar problem, which caused the same error:
If you are having to database connections with same credentials oci_connect() will return the same connection handle for both connections.
This behaviour is described here: http://php.net/manual/de/oci8.connection.php
If a rollback or commit is performed for one connection, this also affects the other connection as they reference the same handle.
Instead oci_new_connect() should be used, which really creates independent "physical" connections.
In fact this issue must be fixed in the yajra/laravel-pdo-via-oci8 package in the Oci8::connect() function.
This issue is stale because it has been open for 30 days with no activity.
This issue was closed because it has been inactive for 7 days since being marked as stale.