title: MySQL is not using INDEX in subquery
body: <p>I have these tables and queries as defined in <a href="http://www.sqlfiddle.com/#!2/d67fc/9">sqlfiddle</a>.</p>
  
  <p>First my problem was to group people showing LEFT JOINed visits rows with the newest year. That I solved using subquery. </p>
  
  <p>Now my problem is that that subquery is not using INDEX defined on <code>visits</code> table. That is causing my query to run nearly indefinitely on tables with approx 15000 rows each.</p>
  
  <p>Here's the query.  The goal is to list every person once with his newest (by year) record in visits table. </p>
  
  <p>Unfortunately on large tables it gets real sloooow because it's not using INDEX in subquery.</p>
  
  <pre><code>SELECT *
  FROM people
  LEFT JOIN (
    SELECT *
    FROM visits
    ORDER BY visits.year DESC
  ) AS visits
  ON people.id = visits.id_people
  GROUP BY people.id
  </code></pre>
  
  <p>Does anyone know how to force MySQL to use INDEX already defined on <code>visits</code> table?</p>