title: Ruby-on-Rails: Selecting distinct values from the model
body: <p>The docs:
  <a href="http://guides.rubyonrails.org/active_record_querying.html#selecting-specific-fields">http://guides.rubyonrails.org/active_record_querying.html#selecting-specific-fields</a></p>
  
  <p>Clearly state that:</p>
  
  <pre><code>query = Client.select(:name).distinct
  # =&gt; Returns unique names
  </code></pre>
  
  <p>However, when I try that in my controller, I get the following error:</p>
  
  <pre><code>undefined method `distinct' for #&lt;ActiveRecord::Relation:0xb2f6f2cc&gt;
  </code></pre>
  
  <p>To be clear, I want the distinct names, like ['George', 'Brandon'], not the clients actual records. Is there something that I am missing?</p>