Migrating an alternate DB connection

I shared the bug report here: http://code.google.com/p/yii/issues/detail?id=2026

Basically, it’s dropping the alternate connectionId, applying the changes to the default DB while logging the change to the connection identified in connectionId.

Wondering if anyone can think of a good work around that would enable us to synchronise the test and primary databases with the migration code. Any way to specify an alternate console.php configuration file perhaps?

P.S.- I think this migrate functionality is brilliant.

Hey, just made a comment on the reported issue. Actually you can change the function instantiateMigration() in file [font="monospace"]framework/cli/commands/MigrateCommand.php to look like:[/font]




	protected function instantiateMigration($class)

	{

		$file=$this->migrationPath.DIRECTORY_SEPARATOR.$class.'.php';

		require_once($file);

                $migration = new $class;

                $migration->setDbConnection($this->getDbConnection());

		return $migration;

	}



Works beautifully. Thanks!

Thank you both!

Thank you all!