title: How to connect to MYSQL database manually with Rails?
body: <p>I want to connect to a MySQL database without adding it to database.yml. How can I connect and run a query on that database?</p>
  
  <p>I understand I need to do something like this, but what's the code for actually making the connection to the specific IP/port first?</p>
  
  <pre><code>query = "SELECT 1"
  ActiveRecord::Base.connection.execute(query)
  </code></pre>