Inside the Zend Framework Application.ini I have the following configuration:
resources.multidb.sga.adapter = "PDO_MYSQL"
resources.multidb.sga.host = "host.acula.net"
resources.multidb.sga.username = "usuario"
resources.multidb.sga.password = "senha"
resources.multidb.sga.port = "3306"
resources.multidb.sga.dbname = "base"
But I need HOST to be dynamic . It will be changed as you choose in a Switch on the Controller.
switch ($unidade) {
case 'Gama':
$host = 'sgagama.servidor.br';
$unidade = 5;
$this->realizaConsultaSga($mes, $ano, $unidade);
break;
case 'Sede':
$host = 'sgasede.servidor.br';
$unidade = 1;
$this->realizaConsultaSga($mes, $ano, $unidade);
break;
....
How do I make this work for this idea?