title: Using And operator with subquery
body: <p>Find the  sid who have reserved a red and a green boat.</p>
  
  <pre><code>Table reserves
  
  sid    bid
  22     101
  22     102
  22     103
  31     103
  32     104
  
  Table Boats
  
  Bid   Color
  101   blue
  102   red
  103   green
  104   red
  </code></pre>
  
  <p>Is it possible to use and operator with sub query something like this</p>
  
  <pre><code>select sid from reserves where bid in
  (select bid from boats where color='red') and 
  (select bid from boats where color='green') ;
  </code></pre>
  
  <p>Here I need check whether "bid" is present in the results of both 1st and 2nd sub query then select the sid.It doesn't considers the result of second sub query result for me though. </p>