title: Search active record for partial strings in a column
body: <p>I need to perform a search on a single model Journal, after my product search results are returned. </p>
  
  <p>Is there a way to search a Journal headline with only part of the full string?</p>
  
  <pre><code>def index
      @product_results = Gemgento::Search.products(params[:query])
      @editorial_results = Journal.where("headline LIKE ?", "#{params[:query]}")   
  end
  </code></pre>
  
  <p>For example. Say my last journal object had the headline: "stack overflow blogpost"
  if I query active record with:</p>
  
  <pre><code>@editorial_results = Journal.where("headline LIKE ?", "stack overflow")
  </code></pre>
  
  <p>As I have  it now, it still requires a direct match on  the string.  </p>
  
  <p>Searching through <a href="http://guides.rubyonrails.org/active_record_querying.html">http://guides.rubyonrails.org/active_record_querying.html</a> it seems that this is the correct way to do this, despite the warnings of sql injection.</p>
  
  <p>Is there a way to structure the search so it will return the last entry? (without using a search library?) </p>