title: how to structure a mysql subquery
body: <p>I have a users table, and an appointments table.  For any given day, I would like a query that selects </p>
  
  <p>1) the user_id the appointment is scheduled with</p>
  
  <p>2) the number of appointments for that user for the specified day.  </p>
  
  <p>It seems I can one or the other, but I'm unsure of how to do it with one query.  For instance, I can do:</p>
  
  <pre><code>SELECT user_id FROM appt_tbl WHERE DATE(appt_date_time) = '2012-10-14' 
  group by user_id;
  </code></pre>
  
  <p>Which will give me the users that have an appointment that day, but how can I add to this query another column that will give me how many appointments each user has?  Assuming I need some kind of subquery, but I'm unsure of how to structure that.</p>