I am currently using Laravel 5.4. I have a separate database per client. I would like to run database migrations in all my client databases. The database names are in the format of clientdb_{clientid}. I have tried using
Config::set("database.connections.mysql", ["database" =>
"clientdb_".$client['id'],
"username" => "root","password" => ""]);
$this->callSilent('migrate',
[ '--path' => 'database/migrations/clients','--database'=>'clientdb_'.$client['id']]);
but I am getting exception called
[InvalidArgumentException] Database [clientdb_1] not configured.