title: Select the record with the MIN(DATE)
body: <p>So, a very simple query, but I'm not sure if I got it right since I'm making this on paper and don't have a DBMS where I can try it on.
  It's an exercise for a college exam.
  I have this table:</p>
  
  <pre><code>    Serv_req
      =============
  PK  Svr_ID
      State
      Req_Date
      Description
  </code></pre>
  
  <p>They are simply asking me to show the data for the oldest Serv_Req that has "Open" as state.</p>
  
  <p>What I wrote so far is:</p>
  
  <pre><code>SELECT Svr_ID, State, Description, MIN(Req_Date)
  FROM Serv_req
  WHERE State LIKE 'Open'
  GROUP BY Svr_ID, State, Description
  </code></pre>
  
  <p>Now, will this return ONLY the record with the info for the oldest Svr_req? or will it return a list of ALL "Open" requirements with just the date of the oldest one at the end?</p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>I forgot to mention. Unfortunatelly, course rules don't allow us to use <code>SELECT TOP</code>, <code>LIMIT 1</code>, or even subqueries to create aux tables in the <code>FROM</code> statement.</p>
  
  <p>Thanks in advance for your help guys!</p>
  
  <p><strong>UPDATE 2</strong>
  Ok, so, after seeing the first query I wrote is totally wrong, I'm giving it a second try.
  Please tell me if you think this is right:</p>
  
  <pre><code>SELECT Svr_id, State, Description
  FROM Serv_req
  WHERE State LIKE 'Open'
  AND Req_Date = (SELECT MIN(S1.Req_date)
                  FROM Serv_req S1
                  WHERE S1.State LIKE 'Open'
                  )
  </code></pre>
  
  <p>I know this is not the clearest/most performing way to do this query, but with the limitation my course imposes, it's the best I could come up with. What do you guys think? Does it seem right?</p>