title: Rails "where" method to find parent by child attribute
body: <p>I have a Rails app where I'm trying to create a list of parent classes based on the date of their child classes.</p>
  
  <p>right now I have:</p>
  
  <pre><code>orders = Order.where("order_reminders.date &lt; ?", 1.month.from_now)
  </code></pre>
  
  <p>But I'm receiving an error.</p>
  
  <p>"no such column: order_reminders.date"</p>
  
  <p>I'm sure my problem is with my query but I'm not sure how to fix it.</p>