title: Possible to join Rails Action Text Model
body: <p>Using Rails 6 rc1, I'm doing a query on a model called 'Job'.</p>
  
  <p><strong>Job Model (job.rb):</strong></p>
  
  <pre><code>has_rich_text :description
  belongs_to :company, dependent: :destroy, required: false
  
  def self.search(query)  
    joins(:company, :description)
    .where.not(has_ended: true)
    .where("jobs.title ILIKE ?", query)
    .where("jobs.description ILIKE ?", query)
    .where("companies.name ~* ?", "^#{query}") # https://www.postgresql.org/docs/8.3/functions-matching.html
  end
  </code></pre>
  
  <p>That's exactly what I have. So far my issue is with the inclusion of <code>has_rich_text</code>. The error, when replicated in the rails console <code>Job.joins(:description)</code>:</p>
  
  <blockquote>
    <p>ActiveRecord::AssociationNotFoundError (Association named 'description' was not found on Job; perhaps you misspelled it?</p>
  </blockquote>
  
  <p>When searching "hight and low", I could not find any documentation on this level of query. I havent tried <code>scope</code> <a href="https://guides.rubyonrails.org/active_record_querying.html#joining-tables" rel="nofollow noreferrer">mentioned here</a>.</p>