You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Switch database with USE where supported is a more efficient manner than resetting the connection entirely, and retains ability to not reset transaction level (which assists in using RefreshDatabase test trait).
I currently have tested code to do this with MySQL and documented the process for PostgreSQL and MS SQL, SQLite does not support this. If interest is present for this, I would pursue a Laravel PR for adding the database specific functionality, and upon that success, I would look to integrate the generic API from Laravel in this package.
This discussion is to find out from the maintainers if this is a desirable feature, thus worth the effort to PR both in Laravel and here.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Switch database with
USE
where supported is a more efficient manner than resetting the connection entirely, and retains ability to not reset transaction level (which assists in using RefreshDatabase test trait).I currently have tested code to do this with MySQL and documented the process for PostgreSQL and MS SQL, SQLite does not support this. If interest is present for this, I would pursue a Laravel PR for adding the database specific functionality, and upon that success, I would look to integrate the generic API from Laravel in this package.
This discussion is to find out from the maintainers if this is a desirable feature, thus worth the effort to PR both in Laravel and here.
Beta Was this translation helpful? Give feedback.
All reactions