/ Published in: Ruby
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
class RegularModel < ActiveRecord::Base end class MyModel < ActiveRecord::Base establish_connection "another_db" end # these then use the following, located in database.yml development: adapter: mysql database: firstdb pool: 5 timeout: 5000 another_db: adapter: mysql database: second_db_table pool: 5 timeoute: 5000