title: more than one database per model
body: <pre><code>class Service &lt; ActiveRecord::Base
  
  establish_connection(
    :adapter  =&gt; "mysql",
    :host     =&gt; "myip",
    :username =&gt; "myusername",
    :password =&gt; "mypassword",
    :database =&gt; "mydatabase"
  )
  
  end
  </code></pre>
  
  <p>This works </p>
  
  <pre><code>Service.all #connects to mydatabase
  </code></pre>
  
  <p>But i need something like that.</p>
  
  <pre><code>Service.use(mydatabase1).all #connects to mydatabase1
  Service.use(mydatabase2).all #connects to mydatabase2
  </code></pre>
  
  <p>How can i achieve this?</p>
  
  <h2>Update</h2>
  
  <p>Database names are dynamic. I want Service model to connect database dynamically. 
  When i type <code>Service.use(weeweweaszxc).all</code> it has to use weeweweaszxc database.</p>