Skip to content
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

Undefined variable: host #104

Closed
rxng opened this issue Aug 4, 2020 · 3 comments
Closed

Undefined variable: host #104

rxng opened this issue Aug 4, 2020 · 3 comments

Comments

@rxng
Copy link

rxng commented Aug 4, 2020

Hi, I am following the instructions from https://docs.spatie.be/laravel-multitenancy/v1/installation/using-multiple-databases/

and am at the step where I am supposed to run
php artisan migrate --path=database/migrations/landlord --database=landlord

However, I am getting this error:
Undefined variable: host (SQL: select * from information_schema.tables where table_schema = landlord and table_name = migrations and table_type = 'BASE TABLE')

I've checked my mysql, it is running, and I have created the database called landlord.

Just wondering why this might be occurring and if there is a fix?

@freekmurze
Copy link
Member

Could you provide us with the complete stack trace?

@masterix21
Copy link
Collaborator

@rxng seems that you using an undefined $host variable in your config/database.php or in your DatabaseSwitchTask. As said @freekmurze, please post your stack trace. Thanks

@masterix21
Copy link
Collaborator

masterix21 commented Aug 19, 2020

@rxng, feel free to reply to the issue when you're ready, and I will open it again. I'm closing it due to inactivity.

Thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants