-
Notifications
You must be signed in to change notification settings - Fork 11.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Migration overwrite $connection property don't work #31060
Comments
If the connection name is hardcoded you can use: Schema::connection('pgsql')->table(...) |
Please see the answer above. |
Yes i know this is a solution, but by the concept presented in the $connection property comment is not working... /**
* The name of the database connection to use.
*
* @var string|null
*/
protected $connection; |
Indeed the The @iAmine Is there a way to make |
@iraklisg Yes, you can check the pull request i have made. extend the Migrator class and make the needed changes. |
I am also having this issue. The documentation states this is the way to set your migration connection. Laravel v8.60.0 (PHP v7.4.11) |
Description:
I overwrite $connection property in migration, but still migrate on the default database connection
as its described on the "abstract class Migration"
The migration file i used
Note: the default connection i use on .env is mysql
The text was updated successfully, but these errors were encountered: