title: SELECT a single field by ordered value
body: <p>Consider the following two tables:</p>
  
  <pre><code>student_id  score   date
  -------------------------
  1           10      05-01-2013
  2           100     05-15-2013
  2           60      05-01-2012
  2           95      05-14-2013
  3           15      05-01-2011
  3           40      05-01-2012
  
  
  class_id        student_id
  ----------------------------
  1               1
  1               2
  2               3
  </code></pre>
  
  <p>I want to get unique class_ids where the score is above a certain threshold for at least one student, ordered by the latest score. </p>
  
  <p>So for instance, if I wanted to get a list of classes where the score was > 80, i would get class_id 1 as a result, since student 2's latest score was above > 80. </p>
  
  <p>How would I go about this in t-sql?</p>