title: Aggregate functions - getting columns not included in the GROUP BY clause
body: <p>I have a table which has three fields (item_id, source, and price).  (item_id, source, and price) together make up the primary key.</p>
  
  <pre><code>item_id    source      price
  -------    -------     -----
  1          paris       13
  1          london      12
  1          newyork     15
  2          paris       22
  2          london      15
  2          newyork     14
  </code></pre>
  
  <p>For each item_id, I want to know the cheapest place to get it, and the price I will pay at that place.  For the example above, I'd like to see the following output:</p>
  
  <pre><code>item_id    source     price
  -------    -------    ---------
  1          london     12
  2          newyork    14
  </code></pre>
  
  <p>Is there a simple way to do this without mentioning the table name twice? I'm using MySQL, so I can't use a WITH clause.</p>
  
  <p>I've taken a look at the joined two-query solution in another user's question (<a href="https://stackoverflow.com/questions/821811/group-related-records-but-pick-certain-fields-from-only-the-first-record">Group related records, but pick certain fields from only the first record</a>), but I'd really like to avoid mentioning the table twice.  The problem is that the simple table in this question actually represents an inline view in my real problem which takes about 5 seconds to create per use, so I'm hoping to find alternatives.</p>