title: ActiveRecord query for a count of new users by day
body: <p>I want to generate a table showing how many users were created each day.</p>
  
  <p>What's the most efficient or elegant ActiveRecord query to do this?</p>
  
  <p>My (simplified) schema looks like this:</p>
  
  <pre><code>create_table "users" do |t|
    t.datetime "created_at"
    t.string   "name"
  end
  </code></pre>
  
  <p>I want a table that looks like this, where the integers are a count of new users each day:</p>
  
  <pre><code>day              new users
  2012-04-01       55
  2012-04-02       63
  2012-04-03       77
  2012-04-04       88
  </code></pre>
  
  <p>I want to generate the table from an array that looks like this:</p>
  
  <pre><code>data_table.add_rows( [
    [ Date.parse("2012-04-01"), 55],
    [ Date.parse("2012-04-02"), 63],
    [ Date.parse("2012-04-03"), 77],
    [ Date.parse("2012-04-04"), 88]
  ] )
  </code></pre>