If the namespace is not used then the commands will perform on top of the default database.
bundle exec rake db:create
bundle exec rake db:migrate
By using the namespace we are going to use all the configuration for our alternate DB.
bundle exec rake pg:db:create
bundle exec rake pg:db:migrate
- From here having a more complex structure with more than one alternative database should be easy.
More info: http://stackoverflow.com/questions/1635885/rails-mysql-postgres-at-the-same-time-in-the-same-app