title: Establishing a second connection in Rails app without using abstract class
body: <p>Initially, this worked to create a second connection:</p>
  
  <pre><code>class OtherDb &lt; ActiveRecord::Base
    self.abstract_class = true
    establish_connection :crawler_production
  
    def self.notify_changes
      sql = ActiveRecord::Base.send(:sanitize_sql_array, ["UPDATE ...", attr1, attr2])
      connection.execute(sql)
  </code></pre>
  
  <p>However, this prevents me from instantiating OtherDb. I would get an error that I can't instantiate an abstract class. So I tried changing to this:</p>
  
  <pre><code>class VtigerDb
    def initialize
      ActiveRecord::Base.establish_connection(:crawler_production)
    end
  
    def notify_changes
      sql = ActiveRecord::Base.send(:sanitize_sql_array, ["UPDATE ...", attr1, attr2])
      ActiveRecord::Base.connection.execute(sql)
    end
  </code></pre>
  
  <p>However, this gives me another error:</p>
  
  <pre><code>Mysql2::Error: Table 'original_db.other_db_table' doesn't exist:
  </code></pre>
  
  <p>How can I access a second connection in a Rails app, without forcing that class to be an abstract class?</p>