title: How to use INNER JOIN correctly in MySQL?
body: <p>I get a syntax error in this SQL query below, where it tells me INNER JOIN is not correctly used. How can I solve this? Thanks!</p>
  <pre class="lang-sql prettyprint-override"><code>select m1.player, count(distinct m1.species) 
  from phonemon as m1
  group by player
  INNER JOIN 
  select ti.title, count(*)
  from type as t1, species as s1
  where s1.type1 = t1.id or s1.type2 = t1.id
  group by t1.title
  </code></pre>